Add installation instructions
[uccvend-vendserver.git] / Makefile
1 .PHONY: clean-pyc clean-build docs clean
2
3 help:
4         @echo "clean - remove all build, test, coverage and Python artifacts"
5         @echo "clean-build - remove build artifacts"
6         @echo "clean-pyc - remove Python file artifacts"
7         @echo "clean-test - remove test and coverage artifacts"
8         @echo "lint - check style with flake8"
9         @echo "test - run tests quickly with the default Python"
10         @echo "test-all - run tests on every Python version with tox"
11         @echo "coverage - check code coverage quickly with the default Python"
12         @echo "docs - generate Sphinx HTML documentation, including API docs"
13         @echo "release - package and upload a release"
14         @echo "dist - package"
15
16 clean: clean-build clean-pyc clean-test
17
18 clean-build:
19         rm -fr build/
20         rm -fr dist/
21         rm -fr *.egg-info
22
23 clean-pyc:
24         find . -name '*.pyc' -exec rm -f {} +
25         find . -name '*.pyo' -exec rm -f {} +
26         find . -name '*~' -exec rm -f {} +
27         find . -name '__pycache__' -exec rm -fr {} +
28
29 clean-test:
30         rm -fr .tox/
31         rm -f .coverage
32         rm -fr htmlcov/
33
34 lint:
35         flake8 uccvend-vendserver tests
36
37 test:
38         python setup.py test
39
40 test-all:
41         tox
42
43 coverage:
44         coverage run --source uccvend-vendserver setup.py test
45         coverage report -m
46         coverage html
47         open htmlcov/index.html
48
49 docs:
50         rm -f docs/uccvend-vendserver.rst
51         rm -f docs/modules.rst
52         sphinx-apidoc -o docs/ uccvend-vendserver
53         $(MAKE) -C docs clean
54         $(MAKE) -C docs html
55         open docs/_build/html/index.html
56
57 release: clean
58         python setup.py sdist upload
59         python setup.py bdist_wheel upload
60
61 dist: clean
62         python setup.py sdist
63         python setup.py bdist_wheel
64         ls -l dist

UCC git Repository :: git.ucc.asn.au