-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathMakefile
More file actions
47 lines (36 loc) · 814 Bytes
/
Makefile
File metadata and controls
47 lines (36 loc) · 814 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
SRC = cachetory tests
.PHONY: all
all: install lint test build docs
.PHONY: clean
clean:
find . -name "*.pyc" -delete
rm -rf *.egg-info build
rm -rf coverage*.xml .coverage
poetry env remove --all
.PHONY: install
install:
poetry install --sync --all-extras --with=dev --with=docs
.PHONY: lint
lint: lint/ruff lint/mypy
.PHONY: lint/ruff
lint/ruff:
poetry run ruff format --diff $(SRC)
poetry run ruff check $(SRC)
.PHONY: lint/mypy
lint/mypy:
poetry run mypy $(SRC)
.PHONY: format
format: format/ruff
.PHONY: format/ruff
format/ruff:
poetry run ruff format $(SRC)
poetry run ruff check --fix $(SRC)
.PHONY: test
test:
DJANGO_SETTINGS_MODULE=tests.backends.django.settings poetry run pytest tests
.PHONY: build
build:
poetry build
.PHONY: docs
docs:
poetry run mkdocs build --site-dir _site