Skip to content

Add Go CLI guidance to Base standards #414

@codeforester

Description

@codeforester

Base will likely need Go CLIs as Banyan Labs work begins. STANDARDS.md should capture lightweight Go CLI guidance now without committing Base to building a Go framework package.

Scope:

  1. Add a Go standards section to STANDARDS.md.
  2. Recommend Cobra as the default Go CLI framework for non-trivial CLIs.
  3. Make clear that Base should orchestrate Go CLIs through manifests, basectl run, and basectl test; Go CLIs should not use base-wrapper.
  4. Document expected Go CLI behavior: logs to stderr, primary output to stdout, explicit exit codes, --dry-run/--yes for destructive commands, and JSON output through encoding/json.
  5. Recommend conventional Go project layout such as cmd/<tool>/main.go plus internal/....
  6. State that a future base-go-cli helper package should be considered only after repeated real boilerplate appears in Banyan Labs or other projects.

Acceptance criteria:

  • STANDARDS.md includes concise Go CLI guidance.
  • The guidance does not overbuild or imply an immediate Base Go framework.
  • The changelog records the documentation update.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions