Documentation ¶
Index ¶
- type CLI
- func (cli *CLI) GetSubCmdRelativeFileName(rootCmdName string, subCommandFolder string, group string, fileName string) string
- func (cli *CLI) HasDescription() bool
- func (cli *CLI) HasName() bool
- func (cli *CLI) SetCommonValues(workload companionCLIProcessor, isSubcommand bool)
- func (cli *CLI) SetDefaults(workload companionCLIProcessor, isSubcommand bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CLI ¶
type CLI struct { Name string Description string VarName string `json:"-" yaml:"-" validate:"omitempty"` FileName string `json:"-" yaml:"-" validate:"omitempty"` IsSubcommand bool `json:"-" yaml:"-" validate:"omitempty"` IsRootcommand bool `json:"-" yaml:"-" validate:"omitempty"` }
CLI defines the command name and description for the root command or subcommand of a companion CLI.
func (*CLI) GetSubCmdRelativeFileName ¶
func (cli *CLI) GetSubCmdRelativeFileName( rootCmdName string, subCommandFolder string, group string, fileName string, ) string
GetSubCmdRelativeFileName will generate a path for a subcommand CLI file that is relative to the root of the repository.
func (*CLI) HasDescription ¶
HasDescription is a helper method which determines if a companion CLI has a description set.
func (*CLI) HasName ¶
HasName is a helper method which determines if a companion CLI has a name set.
func (*CLI) SetCommonValues ¶
SetCommonValues sets the common values for a companion CLI.
func (*CLI) SetDefaults ¶
SetDefaults sets the default values for a companion CLI.
Click to show internal directories.
Click to hide internal directories.