-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathsetup.py
42 lines (38 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
from setuptools import setup
import ast
path = 'bufrpy/__init__.py'
with open(path, 'rU') as file:
t = compile(file.read(), path, 'exec', ast.PyCF_ONLY_AST)
for node in t.body:
if isinstance(node, ast.Assign) and len(node.targets) == 1:
name = node.targets[0]
if isinstance(name, ast.Name) and name.id == '__version__':
version = node.value.s
break
else:
raise ValueError("Could not determine software version")
setup(name="bufrpy",
packages=["bufrpy", "bufrpy.template", "bufrpy.table", "bufrpy.tool"],
version=version,
description="Pyre-Python BUFR decoder",
url="https://github.com/tazle/bufrpy",
author="Tuure Laurinolli",
author_email="[email protected]",
zip_safe=False,
keywords=["bufr"],
install_requires=["bitstring>=3.1.2"],
test_suite="tests",
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)",
"Topic :: Scientific/Engineering"
])