Error UX

star treats error messages as part of the interface. Every error names the operation, the offending input, and the next action — the star repo update to run, the --name to pass, the qualified reference to use.

Typed errors, funneled cleanly

Domain failures callers need to match on are typed enums deriving thiserror — one variant per failure kind, message strings living on the variants, never in ad-hoc throws at call sites. Everything funnels into color-eyre reporting at the command boundary, so panics and handled errors stay visually distinct.

Did-you-mean everywhere

Every miss path gets edit-distance suggestions over the applicable name space — namespaces or template names. Small, dependency-free implementation; strsim only if it earns its keep.

Disambiguation is the flagship interaction

When several repositories provide the same template name, star’s first move is a friendly picker. When there is no TTY, the error is the disambiguation — copy-pasteable commands, one per candidate:

star use rust-cli my-app
error: template `rust-cli` is provided by 2 repositories:
star use jingus/starters#rust-cli my-app
star use star/starters#rust-cli my-app

Exit codes

Code Meaning
0 success
1 any handled error
101 bug (panic)

No finer granularity until something consumes it.

Crash-report hygiene

color-eyre’s reports stay readable when stderr is piped — no ANSI escapes when not attached to a terminal. CI logs stay clean.