A CookieCutter-based template designed to serve as a robust starting point for most startup projects hosted on GitHub.
This template aims to streamline the initial setup and provide a solid foundation for new projects, ensuring best practices are followed from the start.
Visit our website for more details.
- Clean and Modular Structure: Predefined directory structure to keep your code organized.
- CI/CD Integration: Pre-configured GitHub Actions workflows for automated testing and deployment.
- Pre-configured Linters: Integrated with some tools to maintain code quality.
- Docker Support: Ready-to-use Dockerfile and Docker Compose setup for easy containerization.
- Customizable Templates: Modify to fit your project’s specific needs with minimal effort.
- Python 3.8+
- CookieCutter
This repository contains 6 sub-templates. After running cookiecutter, you will be prompted to select one:
| Template | Description | Key Options |
|---|---|---|
cuda |
CUDA project with CMake/XMake | cxx_build_tool, cuda_standard_version |
cxx |
C++ project with CMake/XMake | cxx_build_tool, cxx_standard_version |
go |
Go project | go_version |
py |
Python project | python_version |
rs |
Rust project | crate_type (bin/lib) |
ts |
TypeScript project | node_version |
To generate a new project, run cookiecutter and select a template from the prompt:
cookiecutter gh:x-pt/templateYou will be prompted to:
- Select a template (cuda, cxx, go, py, rs, ts)
- Enter project details (name, slug, description, version, author info, etc.)
- Configure template-specific options (e.g.,
cxx_build_tool,crate_type, etc.)
Example selecting the Python template non-interactively:
cookiecutter --no-input -o my-project gh:x-pt/template templates:pyC++ / CUDA — Choose between CMake and XMake as the build system. The selected build tool's files are kept; the other is removed.
Rust — Choose between bin (executable) and lib (library) crate type.
The unused entry point (main.rs or lib.rs) is removed.
Python — Uses uv for dependency management and project configuration.
Go — Standard Go module layout with cmd/, internal/, and docs/.
TypeScript — Uses npm with Husky for git hooks.
Check out an example project generated with this template:
- Example for C++ with CMake
- Example for C++ with XMake
- Example for CUDA with CMake
- Example for CUDA with XMake
- Example for Golang
- Example for Python
- Example for Rust
- Example for TypeScript
The 6 sub-templates share common cookiecutter variables (project name, slug,
author, etc.) defined in a single source of truth. To regenerate all
cookiecutter.json files after modifying the common definition or adding a new
template:
make gen-configThis runs scripts/generate_cookiecutter_json.py, which merges the common
variable definitions in the script with per-template overrides and writes
cookiecutter.json for each sub-template.
All hooks across sub-templates follow a consistent pattern: template-specific
cleanup (e.g., removing unused build files) followed by git init with
standardized error handling.
We welcome contributions! Please see our CONTRIBUTING.md for guidelines on how to contribute to this project.
This project is licensed under the MIT License - see the LICENSE file for details.