-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
setup.py
executable file
·78 lines (68 loc) · 2.29 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
71
72
73
74
75
76
77
78
#!/usr/bin/env python
import ast
import os
import re
from setuptools import find_packages, setup
here = os.path.dirname(__file__)
with open(os.path.join(here, 'README.rst')) as f:
long_description = f.read()
source_dir = os.path.join(here, 'src', 'check_python_versions')
metadata = {}
with open(os.path.join(source_dir, '__init__.py')) as f:
rx = re.compile('(__version__|__author__|__url__|__licence__) = (.*)')
for line in f:
m = rx.match(line)
if m:
metadata[m.group(1)] = ast.literal_eval(m.group(2))
version = metadata['__version__']
github_url = 'https://github.com/mgedmin/check-python-versions'
setup(
name='check-python-versions',
version=version,
author='Marius Gedminas',
author_email='marius@gedmin.as',
url=github_url,
project_urls={
'Changelog': f'{github_url}/blob/master/CHANGES.rst',
'Issues': f'{github_url}/issues',
'Source Code': github_url,
},
description=(
'Compare supported Python versions in setup.py vs tox.ini et al.'
),
long_description=long_description,
long_description_content_type='text/x-rst',
keywords=(
'python packaging version checker linter setup.py tox travis appveyor'
),
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: GNU General Public License (GPL)',
'Operating System :: OS Independent',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3.13',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
],
license='GPL',
python_requires=">=3.8",
packages=find_packages('src'),
package_dir={'': 'src'},
entry_points={
'console_scripts': [
'check-python-versions = check_python_versions.cli:main',
],
},
install_requires=[
'pyyaml',
'tomlkit',
'typing_extensions; python_version < "3.8"',
],
zip_safe=False,
)