This teaches you how to build CLI command trees with spf13/cobra, the standard Go library for subcommands, flags, and shell completions. It walks you through the RunE hook chain (PersistentPreRunE is where config initialization lives), args validators like ExactArgs and MatchAll, persistent versus local flags, and ValidArgsFunction for dynamic completions. The testing section is solid: it shows you how to use SetArgs and SetOut to test commands in isolation without touching real stdout. One thing to know: cobra and viper solve different problems (command tree versus config layering), and this skill focuses only on the cobra side. If your CLI is just flags and subcommands with no config files, you only need this.
npx skills add https://github.com/samber/cc-skills-golang --skill golang-spf13-cobra