Cookiecutter PyPackage is a Cookiecutter template that scaffolds a Python package with production-ready CI/CD and automated PyPI publishing.
The template solves the problem of setting up a modern Python package from scratch with all necessary tooling and infrastructure already configured. It bundles a curated stack including uv for package management, ruff for linting and formatting, pytest for testing, and Typer for CLI frameworks. The approach works by generating a complete project structure with GitHub Actions workflows pre-configured for continuous integration, security-hardened deployments to PyPI using Trusted Publishers and Sigstore attestations, and automatic documentation deployment to GitHub Pages.
Developers should choose this template if they want to start a new Python package without manually configuring linting, type checking, testing across multiple Python versions, or CI/CD pipelines. It suits projects intended for PyPI distribution and those that benefit from GitHub Pages documentation. The template is particularly valuable for teams that want security best practices built in from the start, such as SHA-pinned GitHub Actions, minimal permissions, and token-free PyPI publishing.
The project maintains active engagement with its tooling ecosystem, regularly incorporating updates to dependencies and GitHub Actions through automated Dependabot pull requests. Development activity shows responsiveness to modern Python packaging standards, as evidenced by the adoption of newer tools like uv and the implementation of security-hardened CI/CD patterns. The template receives ongoing maintenance to keep generated projects compatible with current Python versions and best practices.