Debian Codegraph @

Makefile

raw
1
2 PYTHON?=python3
3
4 all:
5 @echo Targets:
6 @echo all: This help
7 @echo prepare: Refresh generated files
8 @echo unittests: All unit tests
9 @echo coverage: Test coverage
10 @echo lint: Pylint
11 @echo nuke: Delete all unversioned files
12 @echo documentation: Documentation
13 @echo tarball: Source distribution
14
15 prepare:
16 $(PYTHON) ./prepare.py
17
18 unittests:
19 $(PYTHON) tests/test_all.py
20
21 coverage:
22 $(PYTHON) -m coverage run --branch --omit "tests/*,/usr/*" tests/test_all.py
23 $(PYTHON) -m coverage html
24
25 lint:
26 -$(PYTHON) -m pylint ptk
27
28 nuke:
29 git clean -dxf
30
31 documentation:
32 cd doc; $(MAKE) html
33 rm -rf html
34 mv doc/build/html .
35
36 tarball: documentation
37 $(PYTHON) -m build --sdist --config-setting=--formats=bztar
38
39 release: tarball
40 $(PYTHON) -m twine upload dist/* --verbose -r pypi