-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
42 lines (36 loc) · 1.13 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
import re
import ast
import setuptools
with open("README.md", "r") as fh:
long_description = fh.read()
VALUES = {
'__version__': None,
'__author__': None
}
with open('parallel/__init__.py', 'r') as f:
tree = ast.parse(f.read())
for node in tree.body:
if node.__class__ != ast.Assign:
continue
target = node.targets[0]
if hasattr(target, 'id') and target.id in VALUES:
VALUES[target.id] = node.value.s
author_name, author_email = re.search(
"(?P<name>.*) <(?P<email>.*)>", VALUES['__author__']).groups()
setuptools.setup(
name="python-parallel",
version=VALUES['__version__'],
author=author_name,
author_email=author_email,
description="Simple parallelism for the everyday developer",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/santiagobasulto/parallel",
packages=['parallel'],
python_requires=">=3.5",
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
],
)