-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
63 lines (49 loc) · 1.03 KB
/
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
PROJECT = $(shell basename $(shell pwd))
ID = rfm/${PROJECT}
all: format lint test clean ## format, lint, test, clean (default)
black:
python -m black --preview .
isort:
python -m isort .
format: black isort ## run the formatters
lint: ## run the linters
python -m pylama
test: ## run the tests
PYTHONDONTWRITEBYTECODE=1 \
python -m pytest \
--random-order \
--verbose \
--capture no \
--failed-first \
--cov \
--exitfirst
clean: ## clean up artefacts
@rm -fr .pytest_cache
@rm -fr $$(find . -name __pycache__)
install: ## install dependencies
python -m pip install -r requirements.txt
generate:
python generator.py
###
build:
podman build \
--build-arg PROJECT=${PROJECT} \
--tag ${ID} .
run:
podman run \
--name ${PROJECT} \
--hostname ${PROJECT} \
--volume $(shell pwd):/opt/${PROJECT} \
--interactive \
--tty \
--rm \
${ID} \
bash
exec:
podman exec \
--interactive \
--tty \
${PROJECT} \
bash
deploy:
curl -X POST -d {} https://api.netlify.com/build_hooks/63adc43ebe17be06775d0d7e