-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
51 lines (37 loc) · 1.27 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
MAKEFLAGS += --always-make
VERSION := $(shell python3 -c "from xargproject.attribute import __version__; print(__version__)")
all: build reinstall test
release: all
git tag -a v${VERSION} -m "release v${VERSION}"
git push origin --tags
clean-cover:
rm -rf cover .coverage coverage.xml htmlcov
clean-tox:
rm -rf .stestr .tox
clean: build-clean test-clean clean-cover clean-tox
upload:
xpip-upload --config-file .pypirc dist/*
build-clean:
xpip-build --debug setup --clean
build-requirements:
pip3 install -r requirements.txt
build: build-clean build-requirements
xpip-build --debug setup --all
install:
pip3 install --force-reinstall --no-deps dist/*.whl
uninstall:
pip3 uninstall -y xargproject
reinstall: uninstall install
test-prepare:
pip3 install --upgrade mock pylint flake8 pytest pytest-cov
pylint:
pylint $(shell git ls-files xargproject/*.py)
flake8:
flake8 xargproject --count --select=E9,F63,F7,F82 --show-source --statistics
flake8 xargproject --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
pytest:
pytest --cov=xargproject --cov-report=term-missing --cov-report=xml --cov-report=html --cov-config=.coveragerc --cov-fail-under=100
pytest-clean:
rm -rf .pytest_cache
test: test-prepare pylint flake8 pytest
test-clean: pytest-clean