Diff of /Makefile [000000] .. [d45a3a]

Switch to unified view

a b/Makefile
1
.PHONY: clean clean-test clean-pyc clean-build help
2
.DEFAULT_GOAL := help
3
4
define PRINT_HELP_PYSCRIPT
5
import re, sys
6
7
for line in sys.stdin:
8
    match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line)
9
    if match:
10
        target, help = match.groups()
11
        print("%-20s %s" % (target, help))
12
endef
13
export PRINT_HELP_PYSCRIPT
14
15
help:
16
    @python -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST)
17
18
clean: clean-build clean-pyc clean-test ## remove all build, test, coverage and Python artifacts
19
20
21
clean-build: ## remove build artifacts
22
    rm -fr build/
23
    rm -fr dist/
24
    rm -fr .eggs/
25
    rm -f output.html
26
    find . -name '*.egg-info' -exec rm -fr {} +
27
    find . -name '*.egg' -exec rm -f {} +
28
29
clean-pyc: ## remove Python file artifacts
30
    find . -name '*.pyc' -exec rm -f {} +
31
    find . -name '*.pyo' -exec rm -f {} +
32
    find . -name '*~' -exec rm -f {} +
33
    find . -name '__pycache__' -exec rm -fr {} +
34
35
clean-test: ## remove test and coverage artifacts
36
    rm -fr .tox/
37
    rm -f .coverage
38
    rm -fr htmlcov/
39
40
lint: ## check style
41
    py.test --pep8 -m pep8
42
43
test: ## run tests quickly with the default Python
44
    py.test
45
46
47
test-all: ## run tests on every Python version with tox
48
    tox
49
50
release: clean ## package and upload a release
51
    python setup.py sdist
52
    twine upload dist/*
53
54
55
dist: clean ## builds source and wheel package
56
    python setup.py sdist
57
    python setup.py bdist_wheel
58
    ls -l dist
59
60
install: clean ## install the package to the active Python's site-packages
61
    python setup.py install