-
Notifications
You must be signed in to change notification settings - Fork 2
/
setup.py
58 lines (50 loc) · 1.69 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
"""This module provides Python bindings for DGILib."""
import sys
from setuptools import setup
with open("docs/README.rst", "r") as fh:
long_description = fh.read()
needs_pytest = {"pytest", "test", "ptr"}.intersection(sys.argv)
pytest_runner = ["pytest-runner", "pytest-benchmark",
"pytest-cov"] if needs_pytest else []
setup(
name="pydgilib",
version="0.2.3",
description="This module provides Python bindings for DGILib.",
long_description=long_description,
long_description_content_type="text/x-rst",
url="https://github.com/EWouters/pydgilib",
author="Erik Wouters",
author_email="[email protected]",
license="BSD-3-Clause",
packages=["pydgilib", "pydgilib_extra", "atprogram"],
dependency_links=[
"https://www.microchip.com/developmenttools/ProductDetails/" +
"ATPOWERDEBUGGER"
],
zip_safe=False,
setup_requires=[
# ... (other setup requirements)
] + pytest_runner,
# tests_require=["pytest", "pytest-benchmark", "pytest-cov"],
extras_require={
'docs': ["Sphinx", "sphinx_rtd_theme"],
'test': ["pytest-runner", "pytest-benchmark", "pytest-cov"], }
)
# TODO: warn if atmel studio not installed.
# NOTE: dev install: pip install -e .[docs,test]
# Update docs:
# cd docs/_build/html
# If you have not cloned the gh-pages branch previously:
# git clone --branch gh-pages https://github.com/EWouters/pydgilib.git
# Generate the docs
# cd ../..
# make.bat html
# cd _build/html
# git add .
# $ git commit - m 'Update docs.'
# $ git push origin gh-pages
# Push release:
# Set version tag in setup.py and docs/conf.py
# Generate docs
# $ python setup.py sdist bdist_wheel
# $ twine upload dist/*