minitor/Makefile

47 lines
835 B
Makefile
Raw Normal View History

2018-02-14 23:37:15 +00:00
env:
virtualenv -p python3 env
2018-04-09 17:44:30 +00:00
./env/bin/pip install -r requirements-dev.txt
2018-02-14 23:37:15 +00:00
2018-02-17 02:09:10 +00:00
.PHONY: run
2018-02-14 23:37:15 +00:00
run: env
./env/bin/python -m minitor.main
2018-02-17 02:09:10 +00:00
2018-04-09 17:44:30 +00:00
.PHONY: test
test: env
tox
2018-02-17 02:09:10 +00:00
.PHONY: build
2018-04-10 00:26:32 +00:00
build: test
2018-02-17 02:09:10 +00:00
./env/bin/python setup.py sdist
./env/bin/python setup.py bdist_wheel
.PHONY: upload
upload: env
./env/bin/twine upload dist/*
.PHONY: upload-test
upload-test: env
./env/bin/twine upload --repository-url https://test.pypi.org/legacy/ dist/*
.PHONY: clean
clean:
rm -fr ./build ./minitor.egg-info ./htmlcov ./.coverage ./.pytest_cache ./.tox
.PHONY: dist-clean
dist-clean: clean
rm -fr ./dist
2018-04-09 17:44:30 +00:00
2018-04-10 00:26:32 +00:00
.PHONY: install-hooks
2018-04-09 17:44:30 +00:00
install-hooks:
tox -e pre-commit -- install -f --install-hooks
.coverage:
tox
htmlcov/index.html: .coverage
./env/bin/coverage html
.PHONY: open-coverage
open-coverage: htmlcov/index.html
open htmlcov/index.html