-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
59 lines (51 loc) · 1.3 KB
/
Makefile
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
.PHONY: help pypi pypi-test docs coverage test clean
help:
@echo "pypi - submit to PyPI server"
@echo "pypi-check - check the distribution for PyPI"
@echo "pypi-test - submit to TestPyPI server"
@echo "docs - generate Sphinx documentation"
@echo "coverage - check code coverage"
@echo "test - run unit tests"
@echo "clean - remove artifacts"
pypi:
python -m build
twine upload dist/*
pypi-check:
python -m build
twine check dist/*
pypi-test:
python -m build
twine upload -r testpypi dist/*
docs:
rm -f docs/calistar.rst
sphinx-apidoc -o docs calistar
cd docs/
$(MAKE) -C docs clean
$(MAKE) -C docs html
coverage:
coverage run --source=calistar -m pytest
coverage report -m
test:
pytest --cov=calistar/ --cov-report=xml
clean:
find . -name '*.pyc' -exec rm -f {} +
find . -name '__pycache__' -exec rm -rf {} +
rm -f .coverage*
rm -f coverage.xml
rm -f docs/calib_*
rm -f docs/target_*
rm -f gaiaxp_6843672087120107264_0.jpg
rm -f gaiaxp_6843672087120107264_spec.dat
rm -f gaiaxp_6843672087120107264_cov.dat
rm -f docs/gaiaxp_6843672087120107264_0.jpg
rm -f docs/gaiaxp_6843672087120107264.dat
rm -f calib_*
rm -f target_*
rm -rf .pytest_cache/
rm -rf docs/_build/
rm -rf docs/.ipynb_checkpoints/
rm -rf build/
rm -rf dist/
rm -rf calistar.egg-info/
rm -rf htmlcov/
rm -rf .tox/