Makefile Commands
This template maximally automates working with the project using a Makefile. It allows you to perform all main actions with a single command, without remembering long utility options.
!
All commands are run as make <command> (for example, make test).
Quick List
!
Makefile
make init # Initialize the project (install dependencies, set up pre-commit)
make run # Run the application locally (without Docker)
make test # Run tests
make lint # Lint code (Ruff, autofix)
make format # Format code (Ruff)
make typecheck # Static type checking (MyPy)
make clean # Clean caches (`__pycache__`, .mypy_cache, .ruff_cache, .pytest_cache)
make serve # Start local documentation server (MkDocs)
Local Development
make initInstalls dependencies via uv and sets up pre-commit hooks.make runRuns the application (__main__.py) in the current environment.make testRuns all automated tests using [pytest].make lintChecks code style and applies autofix using [Ruff].make formatFormats code according to Ruff settings.make typecheckChecks types using [MyPy].make cleanRemoves all tool caches.
Docker:
Development
make dev-buildBuilds the dev Docker image based ondev.Dockerfile.make dev-upRuns the dev container in the background.make dev-stopStops the dev container without removing it.make dev-downStops and removes the dev container.make dev-logsShows logs from the dev container.make dev-execOpens a bash shell in the running dev container.make dev-bashStarts a new bash shell in the dev container (temporary, with .env.development).
Production
make prod-buildBuilds the production Docker image based onprod.Dockerfile.make prod-runRuns the production container in the background.make prod-execOpens a bash shell in the running prod container.make prod-bashStarts a new bash shell in the prod container (temporary, with .env.production and with--rmflag).make prod-logsShows logs from the prod container.
Git/Release
make commitCreates a commit using Commitizen (launches a wizard for conventional commits).make bumpBumps the project version and automatically updatesCHANGELOG.mdandpyproject.toml(Commitizen).
Documentation
make serveStarts a local documentation server (MkDocs).
Help
make helpOutputs a list of all available commands and their short descriptions.
Common Makefile Shortcuts
!
d— shortcut fordockerdc— shortcut fordocker composeur— shortcut foruv run
Notes
!
- All Makefile commands can be used in CI/CD, locally, or in a devcontainer.
- No other scripts or CLIs are needed: all main scenarios are automated via Makefile.
- All container parameters (such as environment variables) are defined in the corresponding
.env.*files.
For more details about used features, see the Features section in the documentation