A minimal Python project template with formatting and linting tools.
-
Install dependencies with uv:
uv sync --extra dev
-
Install pre-commit hooks:
uv run pre-commit install
Alternatively, activate the virtual environment:
source .venv/bin/activate # On Windows: .venv\Scripts\activate pre-commit install
- Black: Code formatter (line length: 79)
- Ruff: Fast Python linter
- Pre-commit: Git hooks for automated checks
Run Black:
uv run black .Run Ruff:
uv run ruff check .
uv run ruff check --fix . # Auto-fix issuesRun pre-commit manually:
uv run pre-commit run --all-files