This is a cookiecutter template for a python project. This cookiecutter was heavily inspired by cookiecutter-hypermodern-python but removes items requiring external services such. This cookiecutter includes:
- Packaging and dependency management with Poetry
- Test automation with Nox
- Linting with pre-commit and Flake8
- Documentation with Sphinx and MyST using the furo theme
- Code formatting with Black and Prettier
- Import sorting with isort
- Testing with pytest
- Command-line interface with typer
- Static type-checking with mypy
- Runtime type-checking with Typeguard
- Check documentation examples with xdoctest
- Generate API documentation with autodoc and napoleon
- Generate command-line reference with sphinx-click
cookiecutter cookiecutter-pythonThen, change to the project directory and initialize a git repository:
git init
git add .
git commit -m "initial commit"Install poetry environment:
poetry installInstall the pre-commit hooks:
nox -s pre-commit -- install