A modern, Python project scaffolder combining the blazing speed of uv with the robust build ecosystem of hatch.
Inspired by PyScaffold, hatchit scaffolds Python packages, fully equipped with automated testing, documentation, and scientific publishing metadata.
You must have uv installed on your system.
pip install hatchitTo create a brand new repository, simply run the hatchit CLI command:
hatchit my-awesome-package --description "A robust new tool" --license MITor to programmatically create a project,
from hatchit import create_hatchit_repository
create_hatchit_repository(project_path = "my-awesome-package", description = "new tool", license = "MIT")This will generate the project in the my-awesome-package directory and initialize a fresh Git repository.
- The GitHub workflows use "trusted publisher workflow" to publish packages to PyPI. Read more instructions here.
- Install tox to handle package tasks. GitHub Actions relies on the tox configuration to test, generate documentation, and publish packages.
- (Optional) Enable the pre-commit.ci bot for your repository.
- (Optional) Install ruff for code formatting.
- (Optional) Setup codecov for coverage reports.
hatchit structures your project around tox and uv. To run your tests during development:
cd my-awesome-package
tox -e defaultTo build your documentation locally and preview:
tox -e docs- GitHub Actions: The included workflows will automatically begin checking your tests on all commits and PR's.
- PyPI: Create a new GitHub Release or tag. The
publish-pypi.ymlworkflow will automatically securely publish your wheel to PyPI via Trusted Publishing. - Zenodo: If you've activated Zenodo for your repository,
hatchitincludes a.zenodo.jsonand will automatically generate DOIs for new releases!