-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (24 loc) · 694 Bytes
/
Makefile
File metadata and controls
28 lines (24 loc) · 694 Bytes
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
.PHONY: help
help:
@echo "Write in the form make <target> VENV=<name_env>"
@echo "List of targets:"
@echo " clean delete __pycache__/, .pytest_cache/"
@echo " tests run all the tests in the tests/"
@echo " create_env create new environment and install requirements.txt packages"
@echo " linter run the pylint"
.ONESHELL:
create_env:
virtualenv $(VENV)
$(VENV)/bin/pip install -r requirements.txt
.PHONY: clean
clean:
find . \( -name '__pycache__' -o -name ".pytest_cache" \) -type d | xargs rm -fr
.PHONY: tests
.ONESHELL:
tests:
. $(VENV)/bin/activate
python -m pytest tests/
.ONESHELL:
linter:
. $(VENV)/bin/activate
find ./src -type f -name "*.py" | xargs pylint