forked from rndusr/stig
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
34 lines (29 loc) · 925 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
VENV_PATH?=venv
PYTHON?=python3
clean:
find . -name "*.pyc" -delete
find . -name "__pycache__" -delete
rm -rf dist build
rm -rf .pytest_cache
rm -rf .tox
rm -rf "$(VENV_PATH)"
venv:
"$(PYTHON)" -m venv "$(VENV_PATH)"
"$(VENV_PATH)"/bin/pip install --upgrade pytest tox asynctest
"$(VENV_PATH)"/bin/pip install --upgrade flake8 isort
"$(VENV_PATH)"/bin/pip install --editable .
# Needed for setup.py
"$(VENV_PATH)"/bin/pip install --upgrade wheel docutils pypandoc restructuredtext_lint pygments
test: venv
. "$(VENV_PATH)"/bin/activate ; \
"$(VENV_PATH)"/bin/pytest --exitfirst tests
# Check if README.org converts correctly to rst for PyPI
"$(PYTHON)" setup.py check -r -s >/dev/null
fulltest: venv
. "$(VENV_PATH)"/bin/activate ; \
tox
flake8 stig tests
isort --check-only stig/**/*.py tests/**/*.py
"$(PYTHON)" setup.py check -r -s >/dev/null
release:
pyrelease CHANGELOG ./stig/__init__.py