mirror of
https://github.com/ipfs/kubo.git
synced 2025-06-29 17:36:38 +08:00
Merge pull request #2662 from ipfs/feature/add-default-to-commands
Added Default to `commands` cmd
This commit is contained in:
@ -34,7 +34,7 @@ func CommandsCmd(root *cmds.Command) *cmds.Command {
|
|||||||
ShortDescription: `Lists all available commands (and subcommands) and exits.`,
|
ShortDescription: `Lists all available commands (and subcommands) and exits.`,
|
||||||
},
|
},
|
||||||
Options: []cmds.Option{
|
Options: []cmds.Option{
|
||||||
cmds.BoolOption(flagsOptionName, "f", "Show command flags"),
|
cmds.BoolOption(flagsOptionName, "f", "Show command flags").Default(false),
|
||||||
},
|
},
|
||||||
Run: func(req cmds.Request, res cmds.Response) {
|
Run: func(req cmds.Request, res cmds.Response) {
|
||||||
showOptions, _, _ := req.Option(flagsOptionName).Bool()
|
showOptions, _, _ := req.Option(flagsOptionName).Bool()
|
||||||
|
Reference in New Issue
Block a user