|
1 #!/usr/bin/env python |
|
2 |
|
3 from setuptools import setup |
|
4 import os |
|
5 import re |
|
6 import io |
|
7 |
|
8 # Read the long description from the readme file |
|
9 with open("README.rst", "rb") as f: |
|
10 long_description = f.read().decode("utf-8") |
|
11 |
|
12 |
|
13 # Read the version parameters from the __init__.py file. In this way |
|
14 # we keep the version information in a single place. |
|
15 def read(*names, **kwargs): |
|
16 with io.open( |
|
17 os.path.join(os.path.dirname(__file__), *names), |
|
18 encoding=kwargs.get("encoding", "utf8") |
|
19 ) as fp: |
|
20 return fp.read() |
|
21 |
|
22 |
|
23 def find_version(*file_paths): |
|
24 version_file = read(*file_paths) |
|
25 version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", |
|
26 version_file, re.M) |
|
27 if version_match: |
|
28 return version_match.group(1) |
|
29 raise RuntimeError("Unable to find version string.") |
|
30 |
|
31 |
|
32 # Run setup |
|
33 setup(name='scc_access', |
|
34 packages=['scc_access'], |
|
35 version=find_version("scc_access", "scc_access.py"), |
|
36 description='Package for interacting with the Single Calculus Chain through the command line.', |
|
37 long_description=long_description, |
|
38 url='https://bitbucket.org/iannis_b/scc-access/', |
|
39 author='Ioannis Binietoglou', |
|
40 author_email='ioannis@inoe.ro', |
|
41 license='MIT', |
|
42 classifiers=[ |
|
43 'Development Status :: 3 - Alpha', |
|
44 'License :: OSI Approved :: MIT License', |
|
45 'Programming Language :: Python :: 2', |
|
46 'Intended Audience :: Science/Research', |
|
47 'Topic :: Scientific/Engineering :: Atmospheric Science', |
|
48 ], |
|
49 keywords='lidar aerosol SCC', |
|
50 install_requires=[ |
|
51 "requests" |
|
52 ], |
|
53 entry_points={ |
|
54 'console_scripts': ['scc_access = scc_access.scc_access:main'], |
|
55 }, |
|
56 ) |