-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
63 lines (53 loc) · 1.62 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
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
:copyright: 2016 PapyrusThePlant
:license: MIT, see LICENSE for more details.
"""
import os
import sys
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
about = {}
with open('strawpoll/__about__.py') as fp:
exec(fp.read(), None, about)
# Utility aliases
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist bdist_wheel')
os.system('twine upload dist/*')
sys.exit()
if sys.argv[-1] == 'info':
for k, v in about.items():
print('{}: {}'.format(k, v))
sys.exit()
# Call setup as usual
with open('requirements.txt') as fp:
install_requires = fp.read().splitlines()
with open('README.rst') as fp:
long_description = fp.read()
setup(name=about['__title__'],
version=about['__version__'],
description=about['__description__'],
long_description=long_description,
author=about['__author__'],
license=about['__license__'],
url=about['__url__'],
packages=['strawpoll'],
include_package_data=True,
install_requires=install_requires,
keywords=about['__title__'],
zip_safe=False,
classifiers=[
'Development Status :: 5 - Production/Stable',
'License :: OSI Approved :: MIT License',
'Intended Audience :: Developers',
'Natural Language :: English',
'Operating System :: OS Independent',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Topic :: Software Development :: Libraries :: Python Modules',
'Topic :: Utilities'
]
)