-
-
Notifications
You must be signed in to change notification settings - Fork 115
/
Makefile
49 lines (39 loc) · 947 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
43
44
45
46
47
48
49
PYTHON ?= python3
TOX ?= tox
COVERAGE ?= coverage
build:
$(TOX) run -m build
install: clean
$(PYTHON) -m pip install --editable .
clean:
$(PYTHON) setup.py clean
rm -rf build
rm -f src/smartcard/scard/_scard*.so
pypi: clean
# files generated by swig
rm -f src/smartcard/scard/scard.py
rm -f src/smartcard/scard/scard_wrap.c
rm -rf dist
# Use the tox 'build' label to generate wheels for all Python versions.
$(TOX) run -m build
python3 -m twine upload dist/*
test:
pytest --verbose
coverage:
$(COVERAGE) erase
$(COVERAGE) run -m pytest
$(COVERAGE) combine
$(COVERAGE) report
$(COVERAGE) html
pylint:
$(PYTHON) -m pylint --errors-only smartcard
ChangeLog.git:
git log --stat --decorate=short > $@
.PHONY: sync-docs
sync-docs: clean
$(TOX) -e docs
rsync \
--recursive --verbose --update --rsh=ssh --links \
build/docs/ \
[email protected]:/home/project-web/pyscard/htdocs/
.PHONY: clean build pypi test