forked from clinc/PyRegistry
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
41 lines (28 loc) · 860 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
.PHONY: format format-check pylint typecheck lint test docs build clean pypi-test pypi-live
PYTHON := python3
all: format lint test docs
format:
$(PYTHON) -m black .
$(PYTHON) -m isort --profile=black .
format-check:
$(PYTHON) -m black --check .
$(PYTHON) -m isort --profile=black --check .
pylint:
$(PYTHON) -m pylint aioregistry tests
typecheck:
$(PYTHON) -m mypy aioregistry
lint: format-check pylint typecheck
test:
$(PYTHON) -m unittest discover -v tests/
docs:
make -C docs html
build:
$(PYTHON) -m build
clean:
rm -rf build dist *.egg-info
pypi-test: build
TWINE_USERNAME=__token__ TWINE_PASSWORD="$(shell gpg -d test.pypi-token.gpg)" \
$(PYTHON) -m twine upload --repository testpypi dist/*
pypi-live: build
TWINE_USERNAME=__token__ TWINE_PASSWORD="$(shell gpg -d live.pypi-token.gpg)" \
$(PYTHON) -m twine upload dist/*