A Copier template for Python projects managed by PDM.
Package management | |
Linting and Formatting | |
Testing | |
Git hooks | |
Documenting | |
Documentation hosting | |
CI/CD | |
Releasing | |
Container image |
To install Copier use pipx
:
pip install --user pipx
pipx install copier
As this template uses custom extensions you have to install copier-templates-extensions
:
pipx inject copier copier-templates-extensions
To create a project from this template:
copier copy --trust "gh:betaboon/copier-python" /path/to/project
This template provides some pdm scripts
Get a full list with pdm run --list
:
Name | Description |
---|---|
test | Run tests |
lint | Run pre-commit |
docs-build | Build docs |
docs-serve | Build and serve docs |
install-git-hooks | Install pre-commit hooks |
It is suggested to create a branch-protection rule for main
.
For GitHub pages publishing, you need to enable publishing with custom action.
For PyPI publishing, you need to create a pypi project with a trusted publisher.