forked from swl10/pyslet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
60 lines (45 loc) · 1.19 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
60
.PHONY: clean-pyc clean-build
help:
@echo "clean-build - remove build artifacts"
@echo "clean-pyc - remove Python file artifacts"
@echo "clean-docs - remove docs"
@echo "clean-cov - remove coverage report"
@echo "test - run tests with the default Python"
@echo "test27 - run tests with python2.7"
@echo "test3 - run tests with default python and -3Wd options"
@echo "docs - generate Sphinx HTML documentation"
@echo "dist - package"
@echo "pep8 - PEP-8 compliance check using flake8"
@echo "flake8 - same as pep8"
@echo "coverage - run coverage to check test coverage"
clean: clean-build clean-pyc clean-docs clean-cov
clean-pyc:
find . -name '*.pyc' -exec rm -f {} +
clean-build:
rm -fr build/
rm -fr dist/
rm -fr *.egg-info
clean-docs:
rm -fr htmldocs/
clean-cov:
rm -fr htmlcov/
test:
python unittests/test.py
test27:
python2.7 unittests/test.py
test3:
python -3 -Wd -W module -t unittests/test.py
docs:
rm -fr htmldocs/
sphinx-build -b html doc htmldocs/
open htmldocs/index.html
dist: clean
python setup.py sdist
ls -l dist
pep8:
./pep8-regression.py
flake8: pep8
coverage:
coverage run --source pyslet unittests/test.py
coverage html
open htmlcov/index.html