A Go CLI project template for use with gonew.
gonew github.com/rasalas/cli-template github.com/rasalas/my-tool
cd my-tool
go run .- Cobra CLI with
--versionflag and exit code handling internal/term/color system with NO_COLOR support- GitHub Actions CI (test matrix: ubuntu + macos) and release workflow
.goreleaser.ymlfor cross-platform releasesCLAUDE.mdtemplate for AI-assisted developmentdocs/decisions/with ADR template
- Update
CLAUDE.mdwith your project's details - Update
cmd/root.go— changeUse,Short,Long, andVersion - Pick a primary color in
internal/term/colors.go - Update binary name in
.goreleaser.yml - Update
.gitignore(replacecli-templatewith your binary name)