cobra
cobra copied to clipboard
A Commander for modern Go CLI interactions
Hi, I'm trying to do something similar to how `taskwarrior` works. They have an interface like: ``` task 45 complete task 242 delete ``` In this case the 45 is...
Sometimes I want to manually define a way that an error is presented to the user (for instance to change color output and such). This PR adds a way to...
Fixed rules: * MD010 - Hard tabs * MD040 - Fenced code blocks should have a language specified * MD041 - First line in a file should be a top-level...
I'm not sure what I'm doing wrong here. I've installed cobra via: `go install github.com/spf13/cobra/cobra` Now, when I run a `cobra init`, anywhere I get just ``` Error: exit status...
## Problem Today, we have wildy inconsistent license headers in our `go` source files. - I notice that many of the `go` files _do not_ have a license header. -...
Other sections like Usage, Aliases, Available Commands, Flags and Additional help topics have two spaces indent.
Documentation of Context() was fixed in #1639, especially the fact that the underlying ctx is set to context.Background when Execute() is called (otherwise returns nil). The documentation of SetContext() states...
This commit adds flag groups which are mutually exclusive but required, as in, at least one of the flags in a group must be supplied. For example: ```go rootCmd.Flags().StringVarP(&authToken, "auth-token",...
This PR would escape bash v2 completions when there are only one completion left and use line-break to separate completions when passing them to `compgen`. This should fix issues described...
Close #1629