Versions in this module Expand all Collapse all v0 v0.1.1 Mar 6, 2023 v0.1.0 Oct 12, 2021 Changes in this version + func ImportantFlag(name string) + func Register(cmd Command, group string) + type Command interface + Execute func(ctx context.Context, f *pflag.FlagSet, args ...interface{}) ExitStatus + Name func() string + SetFlags func(*pflag.FlagSet) + Synopsis func() string + Usage func() string + func Alias(alias string, cmd Command) Command + func CommandsCommand() Command + func FlagsCommand() Command + func HelpCommand() Command + type CommandGroup struct + func (g *CommandGroup) Name() string + func (g CommandGroup) Len() int + func (g CommandGroup) Less(i, j int) bool + func (g CommandGroup) Swap(i, j int) + type Commander struct + Error io.Writer + Explain func(io.Writer) + ExplainCommand func(io.Writer, Command) + ExplainGroup func(io.Writer, *CommandGroup) + Output io.Writer + var DefaultCommander *Commander + func NewCommander(topLevelFlags *pflag.FlagSet, name string) *Commander + func (cdr *Commander) CommandsCommand() Command + func (cdr *Commander) Execute(ctx context.Context, args ...interface{}) ExitStatus + func (cdr *Commander) FlagsCommand() Command + func (cdr *Commander) HelpCommand() Command + func (cdr *Commander) ImportantFlag(name string) + func (cdr *Commander) Name() string + func (cdr *Commander) Register(cmd Command, group string) + func (cdr *Commander) VisitAll(fn func(*pflag.Flag)) + func (cdr *Commander) VisitAllImportant(fn func(*pflag.Flag)) + func (cdr *Commander) VisitCommands(fn func(*CommandGroup, Command)) + func (cdr *Commander) VisitGroups(fn func(*CommandGroup)) + type ExitStatus int + const ExitFailure + const ExitSuccess + const ExitUsageError + func Execute(ctx context.Context, args ...interface{}) ExitStatus