A modern scaffolding tool for creating new Python packages with best practices built-in.
- Fast Setup: Create fully-configured Python packages in seconds
- uv Integration: Modern dependency & venv management using
uv - Testing Ready: Pre-configured
pytestwith coverage - Documentation: Sphinx docs included
- CI/CD: uv-first GitHub Actions workflow (single canonical
ci.yml) - Best Practices: PEP 8 compliant, type hints, pre-commit hooks, type checking
# Install (uv-first)
uv venv
uv sync --all-extrasscaffold-python my_awesome_package /path/to/parent/directorymy_awesome_package/
βββ .github/
β βββ workflows/
β βββ ci.yaml
βββ docs/
β βββ conf.py
β βββ index.rst
βββ tests/
β βββ test_hello.py
βββ my_awesome_package/
β βββ __init__.py
β βββ hello.py
βββ .gitignore
βββ LICENSE
βββ Makefile
βββ README.md
βββ pyproject.toml
βββ requirements-dev.txt
The tool automatically:
- β Validates inputs
- β Creates project structure
- β Initializes git repository
- β
Sets up
uvvirtual environment (preferred) - β Installs dev dependencies
- β Runs initial tests
- β
Installs and runs
pre-commithooks - β Builds documentation
# Create a new package
scaffold-python data_processor /home/user/projects
# Navigate to the new package
cd /home/user/projects/data_processor
# Activate the environment
source .venv/bin/activate
# Run tests
pytest
# Build docs
sphinx-build -b html docs docs/_build/htmlLocal development is uv-first. Use the provided Makefile for convenience or run uv directly.
Using the Makefile (recommended):
# Create or refresh a uv venv and install dev deps
make install
# Run the test suite
make test
# Run linters and type checks
make lint
make type
# Apply formatting (Black/isort)
make format
# Run pre-commit hooks locally
make precommitDirect uv commands:
# Create a venv and install dev extras
uv venv
uv sync --all-extras
# Run tests
uv run pytest
# Run linters
uv run ruff check .
uv run mypy python_project_deployment
# Run pre-commit
uv run pre-commit install
uv run pre-commit run --all-files- Python 3.11+ (recommended)
- uv (strongly recommended) β the scaffolder / CI are uv-first
If uv is not available, the tool will try to fall back to pip, but behaviour and reproducibility are better with uv.
MIT License - see LICENSE file for details.