Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Designs and reviews Go command-line interfaces for predictable names, flags, output streams, exit codes, errors, and testability.
Use this skill ↓86% 91%+5 ptsof test cases passed
Passed 20 of 22 test cases with the skill, and 19 of 22 without it.
3 of 3 safety checks passed
Not used yet
Design the command as a public interface before treating it as an implementation. Keep results pipeable, failures diagnosable, and process-global state at the edge.
| Task | Load |
|---|---|
| Design or change a complete command contract | guidelines.md, workflows/design-command-interface.md |
| Implement flags, streams, environment, or errors | references/command-interface/rules.md, references/command-interface/examples.md |
| Understand the design rationale | references/command-interface/knowledge.md |
| Review an existing command | references/command-interface/checklist.md |
flag.FlagSet over package-global flags in reusable code.os.Exit below the outer process boundary.Guidance is transformed and paraphrased from Ricardo Gerardi, Powerful Command-Line Applications in Go (Pragmatic Bookshelf, 2021),
Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.