generated from aniketmaurya/python-project-template
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile
41 lines (32 loc) · 735 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
build-docs:
cp README.md docs/index.md
docsserve:
mkdocs serve --dirtyreload --livereload
test:
python tests/__init__.py
pytest
coverage: ## Run tests with coverage
coverage erase
coverage run -m pytest
coverage report -m
coverage xml
clean:
rm -rf dist
find . -type f -name "*.DS_Store" -ls -delete
find . | grep -E "(__pycache__|\.pyc|\.pyo)" | xargs rm -rf
find . | grep -E ".pytest_cache" | xargs rm -rf
find . | grep -E ".ipynb_checkpoints" | xargs rm -rf
rm -f .coverage
style:
black .
isort --profile black .
push:
git push && git push --tags
build:
python -m build
publish-test:
$(style clean build)
twine upload -r testpypi dist/*
publish-prod:
$(style clean build)
twine upload dist/*