cobra
cobra copied to clipboard
The default ShellCompDirective can be customized for a command and its subcommands
Closes #2209, #2221
#2221 proposed a solution where the custom DefaultShellCompDirective
only applied to a given command.
In https://github.com/spf13/cobra/pull/2221#discussion_r1923845125, alternative approaches were discussed. We agreed on a recursive solution, where a change applies to a command and its subcommands.
To ease review, I open a new PR for this approach.