mirror of
https://github.com/spf13/cobra
synced 2025-05-05 04:47:22 +00:00
Document option to hide the default completion cmd
Signed-off-by: Marc Khouzam <marc.khouzam@gmail.com>
This commit is contained in:
parent
7045405250
commit
abaa162a74
1 changed files with 5 additions and 0 deletions
|
@ -99,6 +99,11 @@ To tell Cobra *not* to provide the default `completion` command:
|
|||
rootCmd.CompletionOptions.DisableDefaultCmd = true
|
||||
```
|
||||
|
||||
To tell Cobra to mark the default `completion` command as *hidden*:
|
||||
```
|
||||
rootCmd.CompletionOptions.HiddenDefaultCmd = true
|
||||
```
|
||||
|
||||
To tell Cobra *not* to provide the user with the `--no-descriptions` flag to the completion sub-commands:
|
||||
```
|
||||
rootCmd.CompletionOptions.DisableNoDescFlag = true
|
||||
|
|
Loading…
Add table
Reference in a new issue