feat(cmd): SilenceUsage all but root
This commit is contained in:
parent
f6f1376d1a
commit
06e09df829
5 changed files with 30 additions and 25 deletions
|
|
@ -28,11 +28,12 @@ import (
|
|||
|
||||
// delCmd represents the set command
|
||||
var listDbsCmd = &cobra.Command{
|
||||
Use: "list-dbs",
|
||||
Short: "List all dbs.",
|
||||
Aliases: []string{"ls-dbs", "lsd"},
|
||||
Args: cobra.NoArgs,
|
||||
RunE: listDbs,
|
||||
Use: "list-dbs",
|
||||
Short: "List all dbs.",
|
||||
Aliases: []string{"ls-dbs", "lsd"},
|
||||
Args: cobra.NoArgs,
|
||||
RunE: listDbs,
|
||||
SilenceUsage: true,
|
||||
}
|
||||
|
||||
func listDbs(cmd *cobra.Command, args []string) error {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue