forked from Jammy2211/PyAutoArray
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
71 lines (58 loc) · 2.12 KB
/
setup.py
File metadata and controls
71 lines (58 loc) · 2.12 KB
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
from codecs import open
from os.path import abspath, dirname, join
from subprocess import call
from setuptools import find_packages, setup, Command
def version():
with open("autoarray/__init__.py") as f:
lines = f.read().split("\n")
for line in lines:
if "__version__" in line:
return line.split("=")[1].strip(" '\”")
class RunTests(Command):
"""Run all tests."""
description = "run tests"
user_options = []
def initialize_options(self):
pass
def finalize_options(self):
pass
def run(self):
"""Run all tests!"""
errno = call(["py.test", "--cov=autolens", "--cov-report=term-missing"])
raise SystemExit(errno)
this_dir = abspath(dirname(__file__))
with open(join(this_dir, "README.md"), encoding="utf-8") as file:
long_description = file.read()
with open(join(this_dir, "requirements.txt")) as f:
requirements = f.read().split("\n")
setup(
name="autoarray",
version=version(),
description="numpy extension for masked purposes",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/jammy2211/PyAutoArray",
author="James Nightingale and Richard Hayes",
author_email="james.w.nightingale@durham.ac.uk",
include_package_data=True,
license="MIT License",
classifiers=[
"Intended Audience :: Science/Research",
"Topic :: Scientific/Engineering :: Physics",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.2",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
],
keywords="cli",
packages=find_packages(exclude=["docs"]),
install_requires=requirements,
extras_require={"test": ["coverage", "pytest", "pytest-cov"]},
cmd_class={"test": RunTests},
)