File tree Expand file tree Collapse file tree 6 files changed +56
-16
lines changed
Expand file tree Collapse file tree 6 files changed +56
-16
lines changed Original file line number Diff line number Diff line change 11include README.md
22include CHANGES*
33include LICENSE.txt
4- include versioneer.py
5- include apstools/_version.py
4+ include versioneer.py
5+ include apstools/_version.py
Original file line number Diff line number Diff line change 1-
21#-----------------------------------------------------------------------------
32# :author: Pete R. Jemian
432120__license__ += u" (see LICENSE.txt file for details)"
2221__platforms__ = 'any'
2322__zip_safe__ = False
23+ __exclude_project_dirs__ = "docs examples tests" .split ()
24+ __python_version_required__ = ">=3.5"
2425
2526__package_name__ = __project__
2627__long_description__ = __description__
2728
28- __install_requires__ = ('databroker' , 'pandas' , 'xlrd' )
29+ from ._requirements import learn_requirements
30+ __install_requires__ = learn_requirements ()
31+ del learn_requirements
32+
2933__classifiers__ = [
3034 'Development Status :: 5 - Production/Stable' ,
3135 'Environment :: Console' ,
Original file line number Diff line number Diff line change 1+ #-----------------------------------------------------------------------------
2+ # :author: Pete R. Jemian
3+ 4+ # :copyright: (c) 2017-2019, UChicago Argonne, LLC
5+ #
6+ # Distributed under the terms of the Creative Commons Attribution 4.0 International Public License.
7+ #
8+ # The full license is in the file LICENSE.txt, distributed with this software.
9+ #-----------------------------------------------------------------------------
10+
11+
12+
13+ def learn_requirements ():
14+ """
15+ list all installation requirements
16+
17+ ALL packages & version restrictions stated in requirements.txt
18+ """
19+ req_file = 'requirements.txt'
20+ reqs = []
21+
22+ import os
23+ path = os .path .dirname (__file__ )
24+ req_file = os .path .join (path , '..' , req_file )
25+ if not os .path .exists (req_file ):
26+ # not needed with installed package
27+ return reqs
28+
29+ excludes = "versioneer coveralls coverage" .split ()
30+ with open (req_file , 'r' ) as fp :
31+ buf = fp .read ().strip ().splitlines ()
32+ for req in buf :
33+ req = req .strip ()
34+ if req != "" \
35+ and not req .startswith ('#' ) \
36+ and req not in excludes :
37+ reqs .append (req )
38+ return reqs
Original file line number Diff line number Diff line change @@ -32,19 +32,14 @@ build:
3232
3333requirements :
3434 host :
35- - pip
3635 - python
37- - ophyd
38- - databroker
39- - bluesky
40- - pyRestTable
41- - pandas
42- - xlrd
36+ - pip
4337 run :
4438 - python
4539 - ophyd
46- - databroker
40+ - databroker[all]
4741 - bluesky
42+ - historydict
4843 - pyRestTable
4944 - pandas
5045 - xlrd
Original file line number Diff line number Diff line change 11versioneer
22coverage
33coveralls
4- pyRestTable
4+ bluesky
5+ databroker [all ]
6+ historydict
7+ ophyd
58pandas
9+ pyRestTable
610xlrd
Original file line number Diff line number Diff line change 3535 install_requires = package .__install_requires__ ,
3636 name = package .__project__ ,
3737 #platforms = package.__platforms__,
38- packages = find_packages (exclude = ['docs' ,
39- 'examples' , 'tests' ]),
38+ packages = find_packages (exclude = package .__exclude_project_dirs__ ),
4039 url = package .__url__ ,
4140 version = versioneer .get_version (),
4241 cmdclass = versioneer .get_cmdclass (),
4342 zip_safe = package .__zip_safe__ ,
44- python_requires = '>=3.5' ,
43+ python_requires = package . __python_version_required__ ,
4544 )
You can’t perform that action at this time.
0 commit comments