-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathsetup.py
60 lines (47 loc) · 1.63 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
# vi: ft=python sw=4 ts=4 et:
from __future__ import print_function
from __future__ import unicode_literals
from setuptools import setup
from codecs import open
from os import path
import sys
import monotonic_time
# See https://pypi.python.org/pypi?%3Aaction=list_classifiers
classifiers = '''Natural Language :: English
Development Status :: 4 - Beta
License :: OSI Approved :: MIT License
Programming Language :: Python :: 2
Programming Language :: Python :: 3
Operating System :: MacOS :: MacOS X
Operating System :: POSIX :: Linux
Operating System :: POSIX :: BSD :: FreeBSD
Operating System :: Microsoft :: Windows
'''
if sys.version_info[0:2] < (2, 3):
_setup = setup
def setup(**kwargs):
kwargs.pop('classifiers', None)
_setup(**kwargs)
here = path.abspath(path.dirname(__file__))
with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
long_description = f.read()
need_pytest = {'pytest', 'test', 'ptr'}.intersection(sys.argv[1:])
pytest_runner = ['pytest-runner>=2,<3'] if need_pytest else []
setup(
name='monotonic_time',
version=monotonic_time.__version__,
description=monotonic_time.__doc__.split('\n')[0],
long_description=long_description,
author='Gavin Beatty',
author_email='[email protected]',
maintainer='Gavin Beatty',
maintainer_email='[email protected]',
license='MIT',
platforms=['any'],
classifiers=filter(None, classifiers.split('\n')),
url='https://github.com/gavinbeatty/python-monotonic-time',
py_modules=['monotonic_time'],
keywords=['monotonic', 'time', 'clock'],
setup_requires=pytest_runner,
tests_require=['pytest']
)