@@ -10,7 +10,7 @@ COMPOSE_FILE := docker-compose.yml
1010
1111.DEFAULT_GOAL := help
1212
13- .PHONY : help install run test lint import-check check migrate downgrade revision db-up db-down db-logs clean
13+ .PHONY : help install run test lint import-check security-scan check migrate seed downgrade revision db-up db-down db-logs clean
1414
1515help :
1616 @echo " [make:help] Available commands:"
1919 @echo " [make:test] Run pytest"
2020 @echo " [make:lint] Run Ruff checks"
2121 @echo " [make:import-check] Verify src.main imports"
22+ @echo " [make:security-scan] Run dependency vulnerability scan with pip-audit"
2223 @echo " [make:check] Run tests, lint, and import check"
2324 @echo " [make:migrate] Apply Alembic migrations"
25+ @echo " [make:seed] Seed baseline database records"
2426 @echo " [make:downgrade] Roll back one Alembic migration"
2527 @echo " [make:revision] Create an Alembic migration: make revision name=\" describe change\" "
2628 @echo " [make:db-up] Start Docker Compose services"
@@ -42,19 +44,31 @@ test:
4244
4345lint :
4446 @echo " [make:lint] Running Ruff checks"
45- @$(RUFF ) check src tests
47+ @$(RUFF ) check src tests scripts
4648
4749import-check :
4850 @echo " [make:import-check] Verifying src.main imports"
4951 @PYTHONDONTWRITEBYTECODE=1 $(PYTHON ) -c " import src.main; print('import ok')"
5052
53+ security-scan :
54+ @echo " [make:security-scan] Running dependency vulnerability scan"
55+ @if ! command -v pip-audit > /dev/null 2>&1 ; then \
56+ echo " [make:security-scan] pip-audit is not installed. Install it with: pip install pip-audit" ; \
57+ exit 1; \
58+ fi
59+ @pip-audit
60+
5161check : test lint import-check
5262 @echo " [make:check] All checks completed"
5363
5464migrate :
5565 @echo " [make:migrate] Applying Alembic migrations"
5666 @$(ALEMBIC ) upgrade head
5767
68+ seed :
69+ @echo " [make:seed] Running database seeders"
70+ @$(PYTHON ) scripts/seed.py
71+
5872downgrade :
5973 @echo " [make:downgrade] Rolling back one Alembic migration"
6074 @$(ALEMBIC ) downgrade -1
0 commit comments