-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
49 lines (41 loc) · 1.05 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
.PHONY: lint
lint:
pylint setup.py
pylint src/into_dbus_python
pylint tests
bandit setup.py
# Ignore B101 errors. We do not distribute optimized code, i.e., .pyo
# files in Fedora, so we do not need to have concerns that assertions
# are removed by optimization.
bandit --recursive ./src --skip B101
bandit --recursive ./tests
pyright
.PHONY: test
test:
python3 -m unittest discover --verbose tests
.PHONY: coverage
coverage:
coverage --version
coverage run --timid --branch -m unittest discover tests
coverage report -m --fail-under=100 --show-missing --include="./src/*"
.PHONY: fmt
fmt:
isort setup.py src tests
black .
.PHONY: fmt-travis
fmt-travis:
isort --diff --check-only setup.py src tests
black . --check
.PHONY: upload-release
upload-release:
python setup.py register sdist upload
.PHONY: yamllint
yamllint:
yamllint --strict .github/workflows/main.yml
.PHONY: package
package:
(umask 0022; python -m build; python -m twine check --strict ./dist/*)
.PHONY: legacy-package
legacy-package:
python3 setup.py build
python3 setup.py install