An open API service indexing awesome lists of open source software.

https://github.com/zigai/python-project-template

My personal template for Python projects
https://github.com/zigai/python-project-template

hatch pyproject-toml python-project-template sprout uv uv-python

Last synced: 13 days ago
JSON representation

My personal template for Python projects

Awesome Lists containing this project

README

          

# Python Project Template

My personal template for Python projects.

## Features

* **Modern Python tooling** with [uv](https://docs.astral.sh/uv/) for dependency management and environment setup
* **Pre-configured ```pyproject.toml```**
* **Automated workflows** - [just](https://github.com/casey/just) commands for testing, linting, and building
* **Code quality tools**: [ruff](https://docs.astral.sh/ruff/) for linting and formatting, pre-commit hooks
* **Testing setup** with [pytest](https://docs.pytest.org/en/stable/) and [Hatch](https://hatch.pypa.io/latest/) for cross-version testing
* **GitHub Actions integration**: optional workflows for linting, testing and PyPI publishing
* **Conditional repo setup**: if `gh` is installed, optionally create a public/private GitHub repo
* **Licenses from** [choosealicense.com](https://choosealicense.com/)
* **Basic ```README.md```** with badges and installation instructions

## Requirements

* Python 3.12 or higher
* [sprout](https://github.com/zigai/sprout)
* Git

## Usage

```bash
sprout "https://github.com/zigai/python-project-template.git" /path/to/your/project
```

## Generated Project Structure

```text
your-project/
├── your_package/
│ └── __init__.py
├── tests/
│ └── test_your_package.py
├── .github/workflows/
├── pyproject.toml
├── README.md
├── CONTRIBUTING.md
├── Justfile
├── LICENSE
└── .gitignore
```

## Similar Templates

* [cookiecutter-uv](https://github.com/fpgmaas/cookiecutter-uv)
* [copier-uv](https://github.com/pawamoy/copier-uv)
* [python-copier-template](https://github.com/DiamondLightSource/python-copier-template)

## License

[MIT License](https://github.com/zigai/python-project-template/blob/master/LICENSE)