2022-06-09 22:20:40 +01:00
|
|
|
set dotenv-load
|
|
|
|
|
2022-07-28 18:21:19 +01:00
|
|
|
DEV_COMPOSE := justfile_directory() + "/docker/dev/docker-compose.yml"
|
|
|
|
|
2022-06-09 22:20:40 +01:00
|
|
|
# Recipes
|
|
|
|
@default:
|
|
|
|
just --list
|
|
|
|
|
2022-08-03 21:54:03 +01:00
|
|
|
build:
|
2022-07-28 18:21:19 +01:00
|
|
|
docker-compose -f {{ DEV_COMPOSE }} pull
|
|
|
|
docker-compose -f {{ DEV_COMPOSE }} build
|
2024-01-14 12:59:31 +00:00
|
|
|
docker-compose -f {{ DEV_COMPOSE }} run --entrypoint=bash --rm --no-deps web -c "npm ci"
|
2022-07-28 18:21:19 +01:00
|
|
|
|
|
|
|
@compose +ARGS:
|
|
|
|
docker-compose -f {{ DEV_COMPOSE }} {{ ARGS }}
|
2022-06-09 22:20:40 +01:00
|
|
|
|
|
|
|
@start:
|
|
|
|
honcho start
|
|
|
|
|
|
|
|
@manage +ARGS:
|
|
|
|
./manage.py {{ ARGS }}
|
|
|
|
|
2022-06-12 15:17:28 +01:00
|
|
|
@pip +ARGS:
|
|
|
|
pip {{ ARGS }}
|
|
|
|
|
2022-06-10 16:22:20 +01:00
|
|
|
test *ARGS:
|
2022-10-02 19:25:36 +01:00
|
|
|
TEST=true ./manage.py test {{ ARGS }}
|
2022-06-12 15:17:28 +01:00
|
|
|
|
2022-08-17 19:09:07 +01:00
|
|
|
coverage:
|
2022-10-24 20:41:30 +01:00
|
|
|
TEST=true coverage run ./manage.py test --keepdb
|
2022-08-17 19:09:07 +01:00
|
|
|
coverage report
|
|
|
|
coverage html
|
|
|
|
|
2022-06-12 15:17:28 +01:00
|
|
|
format:
|
2023-07-15 15:10:05 +01:00
|
|
|
ruff check . --fix
|
2022-07-29 08:46:44 +01:00
|
|
|
black .
|
2022-10-05 14:17:00 +01:00
|
|
|
djlint website/ --reformat
|
2022-06-12 19:35:06 +01:00
|
|
|
npm run format
|
2022-06-12 15:17:28 +01:00
|
|
|
|
2022-06-12 19:35:06 +01:00
|
|
|
lint: lint_python lint_node
|
|
|
|
|
|
|
|
lint_python:
|
2023-07-15 15:10:05 +01:00
|
|
|
ruff check .
|
2022-07-29 08:46:44 +01:00
|
|
|
black --check .
|
|
|
|
mypy . --show-error-codes
|
2022-10-05 14:17:00 +01:00
|
|
|
djlint website/ --lint --check
|
2022-06-12 19:35:06 +01:00
|
|
|
|
|
|
|
@lint_node:
|
|
|
|
npm run lint
|
2022-07-29 09:02:09 +01:00
|
|
|
|
|
|
|
@sh:
|
2022-07-29 15:48:43 +01:00
|
|
|
docker-compose -f {{ DEV_COMPOSE }} up -d
|
2024-01-14 12:59:31 +00:00
|
|
|
docker-compose -f {{ DEV_COMPOSE }} exec web bash
|
2022-09-14 09:08:04 +01:00
|
|
|
|
2024-04-07 15:52:40 +01:00
|
|
|
@sh-root:
|
|
|
|
docker-compose -f {{ DEV_COMPOSE }} up -d
|
|
|
|
docker-compose -f {{ DEV_COMPOSE }} exec --user=root web bash
|
|
|
|
|
2022-09-14 09:08:04 +01:00
|
|
|
@down:
|
|
|
|
docker-compose -f {{ DEV_COMPOSE }} down
|