This is a modern Cookiecutter template that can be used to initiate a Python project with all the necessary tools for development, testing, and deployment. It supports the following features:
- uv for dependency management
- Supports src layout](https://packaging.python.org/en/latest/discussions/src-layout-vs-flat-layout/).
- CI/CD with GitHub Actions
- Pre-commit hooks with pre-commit
- Code quality with ruff, mypy, wemake-python-styleguide, deptry and prettier
- Publishing to PyPI by creating a new release on GitHub
- Testing and coverage with pytest and codecov
- Documentation with MkDocs
- Compatibility testing for multiple versions of Python with tox-uv
- Containerization with Docker
- Development environment with VSCode devcontainers
On your local machine, navigate to the directory in which you want to create a project directory, and run the following command:
If cookiecutter is already installed
cookiecutter gh:joeblackwaslike/cookiecutter-uv
If you have uv
installed but not cookiecutter
uvx cookiecutter gh:joeblackwaslike/cookiecutter-uv
or if you don't have uv
installed yet:
pipx install cookiecutter
cookiecutter gh:joeblackwaslike/cookiecutter-uv
Follow the prompts to configure your project. Once completed, a new directory containing your project will be created. Then navigate into your newly created project directory and follow the instructions in the README.md
to complete the setup of your project.
- This project is partially based on Florian Maas's's great cookiecutter-uv repository. Many additional improvements have been added from all the projects I've worked on over the last 12 years or so.
- Florian also credits Audrey Feldroy's great cookiecutter-pypackage repository.
My mission with this is to build the best project starter for python projects that has everything you can want, the ability to customize and/or opt out of most everything, and save you the most time!
I am only one person with very specific preferences. If you have any feedback you can email me at me@joeblack.nyc
. If you find any bugs, mistakes, missed opportunities, or would like to contribute new functionality in any way, I would love to hear about it in an issue, feel free to email me the issue to get my attention.
This project is under continuous iterative improvements as I find bugs, and better and more effective ways to do things. But I can only do so much on my own, so please open an issue if you want to help/contribute and we can iterate and discuss how we can make this happen. If you find an outright bug or mistake, just open a PR and describe all the details there.