generated from webfucktory/python-package-template
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.py
49 lines (40 loc) · 1.52 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
from setuptools import setup
def get_version():
with open("events_manager/__init__.py") as f:
for line in f.read().splitlines():
if line.startswith('__version__'):
return line.split('"' if '"' in line else "'")[1]
else:
raise RuntimeError("Unable to find version string.")
def get_requirements():
with open("requirements.txt") as f:
return [
line.split('#', 1)[0].strip() for line in f.read().splitlines()
if not line.strip().startswith('#')
]
def get_long_description():
with open("README.md", encoding="utf-8") as f:
return f.read()
setup(
name="events-manager",
version=get_version(),
author="webfucktory",
author_email="[email protected]",
description="Python implementation for the Events Management system (aka Observer pattern)",
long_description=get_long_description(),
long_description_content_type="text/markdown",
url="https://github.com/webfucktory/python-events-manager",
packages=['events_manager'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3 :: Only",
],
python_requires='>=3.8',
install_requires=get_requirements(),
)