-
Notifications
You must be signed in to change notification settings - Fork 27
/
setup.py
executable file
·93 lines (73 loc) · 3.02 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#!/usr/bin/env python
import os
from distutils.core import setup
from setuptools.command.test import test as TestCommand
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
# Can't import __meta__.py if the requirements aren't installed
# due to imports in __init__.py. This is a workaround.
meta = {}
exec(read("fissa/__meta__.py"), meta)
install_requires = read("requirements.txt").splitlines()
extras_require = {}
# Notebook dependencies for plotting
extras_require["plotting"] = read("requirements-plots.txt").splitlines()
# Dependencies for generating documentation
extras_require["docs"] = read("requirements-docs.txt").splitlines()
# Test dependencies
extras_require["test"] = read("requirements-test.txt").splitlines()
# Development dependencies
extras_require["dev"] = read("requirements-dev.txt").splitlines()
# Everything as a list. Replicated items are removed by use of set with {}.
extras_require["all"] = sorted({x for v in extras_require.values() for x in v})
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
import pytest
pytest.main(self.test_args)
setup(
name=meta["name"],
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
install_requires=install_requires,
extras_require=extras_require,
version=meta["version"],
author=meta["author"],
author_email=meta["author_email"],
description=meta["description"],
url=meta["url"],
package_dir={meta["name"]: os.path.join(".", meta["path"])},
packages=[meta["name"]],
license="GNU",
long_description=read("README.rst"),
# https://pypi.org/pypi?%3Aaction=list_classifiers
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Bio-Informatics",
"Topic :: Scientific/Engineering :: Information Analysis",
],
project_urls={
"Documentation": "https://fissa.readthedocs.io",
"Source Code": "https://github.com/rochefort-lab/fissa",
"Bug Tracker": "https://github.com/rochefort-lab/fissa/issues",
"Citation": "https://www.doi.org/10.1038/s41598-018-21640-2",
},
cmdclass={"test": PyTest},
)