Rust project scaffolder with template sync and local registries
truss is a small, opinionated CLI for bootstrapping and maintaining Rust
workspaces from reusable template packs. It ships with a few embedded packs,
supports a local template registry, and can diff a generated project against its
template to detect drift.
- Scaffold new workspaces with
truss new. - Sync an existing project back to its template with
truss sync. - Check for drift between a project and its template with
truss check. - Protect local files from being overwritten during sync.
- Template registry for sharing custom packs inside a team or organization.
- Path-safety guards against absolute paths and
..traversal in templates. - Offline rendering using MiniJinja.
Install from source:
cargo install --path crates/truss-cliCreate a workspace from the default pack:
truss new my-project
cd my-project
cargo checkList available packs and check for template drift:
truss templates
truss check --path my-project --template default| Crate | Description |
|---|---|
truss-core |
Core scaffolding library for truss |
truss-cli |
CLI for truss |
| Pack | Kind | Source |
|---|---|---|
agent-rules |
embedded | (built-in) |
default |
embedded | (built-in) |
monorepo |
embedded | (built-in) |
spec-kit |
embedded | (built-in) |
| Command | Description |
|---|---|
truss new |
Create a new project from a template |
truss sync |
Sync a project to a template |
truss check |
Check for drift against a template |
truss update |
Apply upstream template changes with a 3-way merge |
truss extract |
Reverse-scaffold an existing project into a reusable pack |
truss define |
List variables expected by a template pack |
truss templates |
List embedded and registry templates |
truss types |
List and inspect project-type presets |
truss registry |
Manage the local template registry |
truss member |
Manage workspace members |
See docs/CLI.md for the complete command reference.
- Architecture and data flow
- Writing template packs
- Using the template registry
- Full CLI reference
- Contributing
just validate # fmt + check + clippy + test
just secrets # gitleaks + ripsecrets
just docs # regenerate README.md and docs/CLI.md
just docs-check # verify docs are up to dateSee CONTRIBUTING.md.
MIT