Welcome to this Python project template adapted for use with the Cursor editor. This template provides a structured starting point for your Python applications with modern tooling and best practices built in.
This template requires:
- UV for dependency management
- just command runner
- https://marketplace.visualstudio.com/items?itemName=ms-python.python
-
Clone this repository
-
Run the setup script to customize the template for your project:
./project_setup.py "Your Project Name"This script will:
- Rename the
you_app_srcsdirectory to your project name (in snake_case) - Update project name in
pyproject.toml - Update package references in all necessary files
- Update module name in
__init__.py
- Rename the
-
Install dependencies:
just init-venv just update-deps
-
Start developing!
.
├── pyproject.toml # Project configuration and dependencies
├── justfile # Command runner tasks
├── project_setup.py # Project customization script
├── you_app_srcs/ # Main source directory (will be renamed by setup script)
│ ├── __init__.py # Package initialization
│ └── ... # Your modules go here
└── CHANGELOG.md # Documentation of changes
This template uses just for command running:
just fmt- Format codejust lint- Lint codejust update-deps- Update dependencies
The template includes a customization script for easy project setup:
# Example: Set up a project called "Weather Service"
./project_setup.py "Weather Service"This will:
- Rename the package directory to
weather_service - Update project name to "WEATHER-SERVICE" in pyproject.toml
- Update all internal references to use the new package name
This template encourages:
- Composition over inheritance
- Type hints for everything (checked by mypy)
- Comprehensive documentation
- Proper logging practices
- Modern Python features