-
Notifications
You must be signed in to change notification settings - Fork 75
Expand file tree
/
Copy pathMakefile
More file actions
42 lines (35 loc) · 1.12 KB
/
Makefile
File metadata and controls
42 lines (35 loc) · 1.12 KB
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
help:
@echo "Usage:"
@echo " make help: prints this help."
@echo " make test: runs the tests."
@echo " make build: install as for a deployed environment."
@echo " make run-prod: run webserver as in deployed environment."
@echo " make compile: compile the requirements specs."
_uv:
# ensure uv is installed
pip install uv
test:
coverage run -m pytest -vvv tests
coverage report
mypy:
mypy . | mypy-json-report > mypy-ratchet.json
git diff --exit-code mypy-ratchet.json
build: _uv
uv pip install -r requirements.prod.txt -r requirements.dev.txt
rm -rf staticfiles/*
python manage.py collectstatic --no-input
rm -f ccbv.sqlite
python manage.py migrate
python manage.py load_all_django_versions
build-prod:
pip install -r requirements.prod.txt
rm -rf staticfiles/*
python manage.py collectstatic --no-input
rm -f ccbv.sqlite
python manage.py migrate
python manage.py load_all_django_versions
run-prod:
gunicorn core.wsgi --log-file -
compile: _uv
uv pip compile --quiet requirements.prod.in --output-file=requirements.prod.txt
uv pip compile --quiet requirements.dev.in --output-file=requirements.dev.txt