-
Notifications
You must be signed in to change notification settings - Fork 13
/
setup.py
executable file
·70 lines (57 loc) · 1.82 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
"""
setup file for nepali package
- Building a package
pip install build
python -m build
- Publishing a package
You must have twine installed in your system. `pip install twine`
python setup.py sdist bdist_wheel
twine upload dist/*
"""
import os
import sys
import setuptools
GITHUB_URL = "https://github.com/opensource-nepal/py-nepali"
CHANGELOG_URL = "https://github.com/opensource-nepal/py-nepali/blob/main/CHANGELOG.md"
with open("README.md", "r") as fh:
long_description = fh.read()
if sys.argv[-1] == "publish":
if os.system("pip3 freeze | grep twine"):
print("twine not installed.\nUse `pip install twine`.\nExiting.")
sys.exit()
os.system("rm -rf dist")
os.system("python3 setup.py sdist bdist_wheel")
os.system("twine upload dist/*")
sys.exit()
setuptools.setup(
name="nepali",
version="1.1.1",
license="MIT",
author="opensource-nepal",
author_email="aj3sshh@gmail.com, sugatbajracharya49@gmail.com",
description="nepalidatetime compatible with python's datetime feature. "
"Converting nepali date to english, parsing nepali datetime, "
"nepali timezone, and timedelta support in nepali datetime",
long_description=long_description,
long_description_content_type="text/markdown",
keywords=[
"nepali date conversion",
"convert date",
"nepali date time",
"python convert date",
"parse nepali date time",
],
url=GITHUB_URL,
packages=setuptools.find_packages(exclude=["tests*"]),
test_suite="nepali.tests",
install_requires=[],
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
],
project_urls={
"Source": GITHUB_URL,
"Changelog": CHANGELOG_URL,
},
)