membersystem/Justfile

40 lines
1.1 KiB
Makefile
Raw Permalink Normal View History

2024-12-26 00:03:26 +01:00
run:
@echo "Running the server"
docker compose up --watch --remove-orphans
manage *ARGS:
@echo "Running manage command"
docker compose run -w /app/src --rm -u `id -u` app python manage.py {{ARGS}}
build:
@echo "Building the app"
docker compose build
down_with_volumes:
@echo "Taking the docker compose stack down, including volumes"
docker compose down -v
migrate:
@echo "Migrating the database"
docker compose run -w /app/src --rm -u `id -u` app python manage.py migrate
bootstrap_dev_data:
@echo "Bootstrapping development data"
docker compose run -w /app/src --rm -u `id -u` app python manage.py bootstrap_dev_data
reset_db: down_with_volumes migrate bootstrap_dev_data
2024-12-26 00:03:26 +01:00
typecheck:
docker compose run -w /app/src --rm app mypy .
test:
docker compose run --rm app pytest
2024-12-26 00:03:26 +01:00
coverage *ARGS:
@echo "Running tests with coverage"
docker compose run --rm app pytest --cov --cov-report term-missing:skip-covered {{ARGS}}
2024-12-26 00:03:26 +01:00
# You need to install Stripe CLI from here to run this: https://github.com/stripe/stripe-cli/releases
stripe_cli:
stripe listen --forward-to 0.0.0.0:8000/order/stripe/webhook/