-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
42 lines (30 loc) · 838 Bytes
/
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
PROJ_ROOT:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
p ?= $(PROJ_ROOT)
.PHONY: tests coverage coverage-report complexity pypi pre-commit docs
pre-commit:
pre-commit run --all-files
tests:
pytest $(p)
coverage:
coverage run -m pytest -q --disable-warnings . && coverage html -i
coverage-report:
open ./htmlcov/index.html
complexity:
flake8 $(p) --max-complexity 10
pypi:
rm -f dist/*
python -m build
twine upload dist/* --verbose
docs:
# format docs
pydocstringformatter asyncfix/
# Check validity of docs
pydocstyle --convention=google ./asyncfix/
# Builds markdown docs
lazydocs \
--output-path="./docs/reference" \
--overview-file="README.md" \
--src-base-url="https://github.com/alexveden/asyncfix/blob/main/" \
asyncfix
# Finishing and pushing to GH
mkdocs gh-deploy