Documentation ¶
Index ¶
- Constants
- Variables
- func Commands(ctx context.Context, opts ...Option) (*baseCommand, map[string]cli.CommandFactory)
- func GroupedHelpFunc(f cli.HelpFunc) cli.HelpFunc
- func Main(args []string) int
- func NoArgs(c *baseCommand, args []string) error
- type DestroyCommand
- func (c *DestroyCommand) AutocompleteArgs() complete.Predictor
- func (c *DestroyCommand) AutocompleteFlags() complete.Flags
- func (c DestroyCommand) Close() error
- func (c *DestroyCommand) Flags() *flag.Sets
- func (c DestroyCommand) GetExample() string
- func (c *DestroyCommand) Help() string
- func (c DestroyCommand) Init(opts ...Option) error
- func (c DestroyCommand) IsLinux() bool
- func (c DestroyCommand) IsMac() bool
- func (c DestroyCommand) IsWindows() bool
- func (c *DestroyCommand) Run(args []string) int
- func (c *DestroyCommand) Synopsis() string
- type DocGenerateCommand
- func (c DocGenerateCommand) Close() error
- func (c DocGenerateCommand) GetExample() string
- func (c DocGenerateCommand) Help() string
- func (c DocGenerateCommand) Init(opts ...Option) error
- func (c DocGenerateCommand) IsLinux() bool
- func (c DocGenerateCommand) IsMac() bool
- func (c DocGenerateCommand) IsWindows() bool
- func (c *DocGenerateCommand) Run(args []string) int
- func (c DocGenerateCommand) Synopsis() string
- type GenerateHelpCommand
- func (c *GenerateHelpCommand) AutocompleteArgs() complete.Predictor
- func (c *GenerateHelpCommand) AutocompleteFlags() complete.Flags
- func (c GenerateHelpCommand) Close() error
- func (c *GenerateHelpCommand) Flags() *flag.Sets
- func (c GenerateHelpCommand) GetExample() string
- func (c *GenerateHelpCommand) Help() string
- func (c GenerateHelpCommand) Init(opts ...Option) error
- func (c GenerateHelpCommand) IsLinux() bool
- func (c GenerateHelpCommand) IsMac() bool
- func (c GenerateHelpCommand) IsWindows() bool
- func (c *GenerateHelpCommand) Run(args []string) int
- func (c *GenerateHelpCommand) Synopsis() string
- type GeneratePackCommand
- func (c *GeneratePackCommand) AutocompleteArgs() complete.Predictor
- func (c *GeneratePackCommand) AutocompleteFlags() complete.Flags
- func (c GeneratePackCommand) Close() error
- func (c *GeneratePackCommand) Flags() *flag.Sets
- func (c GeneratePackCommand) GetExample() string
- func (c *GeneratePackCommand) Help() string
- func (c GeneratePackCommand) Init(opts ...Option) error
- func (c GeneratePackCommand) IsLinux() bool
- func (c GeneratePackCommand) IsMac() bool
- func (c GeneratePackCommand) IsWindows() bool
- func (c *GeneratePackCommand) Run(args []string) int
- func (c *GeneratePackCommand) Synopsis() string
- type GenerateRegistryCommand
- func (c *GenerateRegistryCommand) AutocompleteArgs() complete.Predictor
- func (c *GenerateRegistryCommand) AutocompleteFlags() complete.Flags
- func (c GenerateRegistryCommand) Close() error
- func (c *GenerateRegistryCommand) Flags() *flag.Sets
- func (c GenerateRegistryCommand) GetExample() string
- func (c *GenerateRegistryCommand) Help() string
- func (c GenerateRegistryCommand) Init(opts ...Option) error
- func (c GenerateRegistryCommand) IsLinux() bool
- func (c GenerateRegistryCommand) IsMac() bool
- func (c GenerateRegistryCommand) IsWindows() bool
- func (c *GenerateRegistryCommand) Run(args []string) int
- func (c *GenerateRegistryCommand) Synopsis() string
- type HasFlags
- type InfoCommand
- func (c InfoCommand) Close() error
- func (c *InfoCommand) Flags() *flag.Sets
- func (c InfoCommand) GetExample() string
- func (c *InfoCommand) Help() string
- func (c InfoCommand) Init(opts ...Option) error
- func (c InfoCommand) IsLinux() bool
- func (c InfoCommand) IsMac() bool
- func (c InfoCommand) IsWindows() bool
- func (c *InfoCommand) Run(args []string) int
- func (c *InfoCommand) Synopsis() string
- type JobStatusError
- type JobStatusInfo
- type ListCommand
- func (c *ListCommand) AutocompleteArgs() complete.Predictor
- func (c *ListCommand) AutocompleteFlags() complete.Flags
- func (c ListCommand) Close() error
- func (c *ListCommand) Flags() *flag.Sets
- func (c ListCommand) GetExample() string
- func (c *ListCommand) Help() string
- func (c ListCommand) Init(opts ...Option) error
- func (c ListCommand) IsLinux() bool
- func (c ListCommand) IsMac() bool
- func (c ListCommand) IsWindows() bool
- func (c *ListCommand) Run(args []string) int
- func (c *ListCommand) Synopsis() string
- type Option
- func WithArgs(args []string) Option
- func WithClient(v bool) Option
- func WithConfig(optional bool) Option
- func WithCustomArgs(args []string, customValidation ValidationFn) Option
- func WithExactArgs(n int, args []string) Option
- func WithFlags(f *flag.Sets) Option
- func WithMaximumNArgs(n int, args []string) Option
- func WithMinimumNArgs(n int, args []string) Option
- func WithNoArgs(args []string) Option
- func WithNoConfig() Option
- func WithSingleApp() Option
- func WithUI(ui terminal.UI) Option
- type PlanCommand
- func (c *PlanCommand) AutocompleteArgs() complete.Predictor
- func (c *PlanCommand) AutocompleteFlags() complete.Flags
- func (c PlanCommand) Close() error
- func (c *PlanCommand) Flags() *flag.Sets
- func (c PlanCommand) GetExample() string
- func (c *PlanCommand) Help() string
- func (c PlanCommand) Init(opts ...Option) error
- func (c PlanCommand) IsLinux() bool
- func (c PlanCommand) IsMac() bool
- func (c PlanCommand) IsWindows() bool
- func (c *PlanCommand) Run(args []string) int
- func (c *PlanCommand) Synopsis() string
- type RegistryAddCommand
- func (c *RegistryAddCommand) AutocompleteArgs() complete.Predictor
- func (c *RegistryAddCommand) AutocompleteFlags() complete.Flags
- func (c RegistryAddCommand) Close() error
- func (c *RegistryAddCommand) Flags() *flag.Sets
- func (c RegistryAddCommand) GetExample() string
- func (c *RegistryAddCommand) Help() string
- func (c RegistryAddCommand) Init(opts ...Option) error
- func (c RegistryAddCommand) IsLinux() bool
- func (c RegistryAddCommand) IsMac() bool
- func (c RegistryAddCommand) IsWindows() bool
- func (c *RegistryAddCommand) Run(args []string) int
- func (c *RegistryAddCommand) Synopsis() string
- type RegistryDeleteCommand
- func (c *RegistryDeleteCommand) AutocompleteArgs() complete.Predictor
- func (c *RegistryDeleteCommand) AutocompleteFlags() complete.Flags
- func (c RegistryDeleteCommand) Close() error
- func (c *RegistryDeleteCommand) Flags() *flag.Sets
- func (c RegistryDeleteCommand) GetExample() string
- func (c *RegistryDeleteCommand) Help() string
- func (c RegistryDeleteCommand) Init(opts ...Option) error
- func (c RegistryDeleteCommand) IsLinux() bool
- func (c RegistryDeleteCommand) IsMac() bool
- func (c RegistryDeleteCommand) IsWindows() bool
- func (c *RegistryDeleteCommand) Run(args []string) int
- func (c *RegistryDeleteCommand) Synopsis() string
- type RegistryHelpCommand
- func (c *RegistryHelpCommand) AutocompleteArgs() complete.Predictor
- func (c *RegistryHelpCommand) AutocompleteFlags() complete.Flags
- func (c RegistryHelpCommand) Close() error
- func (c *RegistryHelpCommand) Flags() *flag.Sets
- func (c RegistryHelpCommand) GetExample() string
- func (c *RegistryHelpCommand) Help() string
- func (c RegistryHelpCommand) Init(opts ...Option) error
- func (c RegistryHelpCommand) IsLinux() bool
- func (c RegistryHelpCommand) IsMac() bool
- func (c RegistryHelpCommand) IsWindows() bool
- func (c *RegistryHelpCommand) Run(args []string) int
- func (c *RegistryHelpCommand) Synopsis() string
- type RegistryListCommand
- func (c *RegistryListCommand) AutocompleteArgs() complete.Predictor
- func (c *RegistryListCommand) AutocompleteFlags() complete.Flags
- func (c RegistryListCommand) Close() error
- func (c *RegistryListCommand) Flags() *flag.Sets
- func (c RegistryListCommand) GetExample() string
- func (c *RegistryListCommand) Help() string
- func (c RegistryListCommand) Init(opts ...Option) error
- func (c RegistryListCommand) IsLinux() bool
- func (c RegistryListCommand) IsMac() bool
- func (c RegistryListCommand) IsWindows() bool
- func (c *RegistryListCommand) Run(args []string) int
- func (c *RegistryListCommand) Synopsis() string
- type Render
- type RenderCommand
- func (c *RenderCommand) AutocompleteArgs() complete.Predictor
- func (c *RenderCommand) AutocompleteFlags() complete.Flags
- func (c RenderCommand) Close() error
- func (c *RenderCommand) Flags() *flag.Sets
- func (c RenderCommand) GetExample() string
- func (c *RenderCommand) Help() string
- func (c RenderCommand) Init(opts ...Option) error
- func (c RenderCommand) IsLinux() bool
- func (c RenderCommand) IsMac() bool
- func (c RenderCommand) IsWindows() bool
- func (c *RenderCommand) Run(args []string) int
- func (c *RenderCommand) Synopsis() string
- type RunCommand
- func (c *RunCommand) AutocompleteArgs() complete.Predictor
- func (c *RunCommand) AutocompleteFlags() complete.Flags
- func (c RunCommand) Close() error
- func (c *RunCommand) Flags() *flag.Sets
- func (c RunCommand) GetExample() string
- func (c *RunCommand) Help() string
- func (c RunCommand) Init(opts ...Option) error
- func (c RunCommand) IsLinux() bool
- func (c RunCommand) IsMac() bool
- func (c RunCommand) IsWindows() bool
- func (c *RunCommand) Run(args []string) int
- func (c *RunCommand) Synopsis() string
- type StatusCommand
- func (c *StatusCommand) AutocompleteArgs() complete.Predictor
- func (c *StatusCommand) AutocompleteFlags() complete.Flags
- func (c StatusCommand) Close() error
- func (c *StatusCommand) Flags() *flag.Sets
- func (c StatusCommand) GetExample() string
- func (c *StatusCommand) Help() string
- func (c StatusCommand) Init(opts ...Option) error
- func (c StatusCommand) IsLinux() bool
- func (c StatusCommand) IsMac() bool
- func (c StatusCommand) IsWindows() bool
- func (c *StatusCommand) Run(args []string) int
- func (c *StatusCommand) Synopsis() string
- type StopCommand
- func (c *StopCommand) AutocompleteArgs() complete.Predictor
- func (c *StopCommand) AutocompleteFlags() complete.Flags
- func (c StopCommand) Close() error
- func (c *StopCommand) Flags() *flag.Sets
- func (c StopCommand) GetExample() string
- func (c *StopCommand) Help() string
- func (c StopCommand) Init(opts ...Option) error
- func (c StopCommand) IsLinux() bool
- func (c StopCommand) IsMac() bool
- func (c StopCommand) IsWindows() bool
- func (c *StopCommand) Run(args []string) int
- func (c *StopCommand) Synopsis() string
- type ValidationFn
- type VersionCommand
- func (c *VersionCommand) AutocompleteArgs() complete.Predictor
- func (c *VersionCommand) AutocompleteFlags() complete.Flags
- func (c VersionCommand) Close() error
- func (c *VersionCommand) Flags() *flag.Sets
- func (c VersionCommand) GetExample() string
- func (c *VersionCommand) Help() string
- func (c VersionCommand) Init(opts ...Option) error
- func (c VersionCommand) IsLinux() bool
- func (c VersionCommand) IsMac() bool
- func (c VersionCommand) IsWindows() bool
- func (c *VersionCommand) Run(args []string) int
- func (c *VersionCommand) Synopsis() string
Constants ¶
const ( // EnvLogLevel is the env var to set with the log level. EnvLogLevel = "NOMAD_PACK_LOG_LEVEL" // EnvPlain is the env var that can be set to force plain output mode. EnvPlain = "NOMAD_PACK_PLAIN" )
Variables ¶
var ( // ErrSentinel is a sentinel value that we can return from Init to force an exit. ErrSentinel = errors.New("error sentinel") // ErrParsingArgsOrFlags should be used in the Init method of a CLI command // if it returns an error. ErrParsingArgsOrFlags = "error parsing args or flags" )
var (
ExposeDocs bool
)
Functions ¶
Types ¶
type DestroyCommand ¶
type DestroyCommand struct {
*StopCommand
}
func (*DestroyCommand) AutocompleteArgs ¶
func (c *DestroyCommand) AutocompleteArgs() complete.Predictor
func (*DestroyCommand) AutocompleteFlags ¶
func (c *DestroyCommand) AutocompleteFlags() complete.Flags
func (DestroyCommand) Close ¶
func (c DestroyCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*DestroyCommand) Flags ¶
func (c *DestroyCommand) Flags() *flag.Sets
func (DestroyCommand) GetExample ¶
func (c DestroyCommand) GetExample() string
func (*DestroyCommand) Help ¶
func (c *DestroyCommand) Help() string
func (DestroyCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*DestroyCommand) Run ¶
func (c *DestroyCommand) Run(args []string) int
func (*DestroyCommand) Synopsis ¶
func (c *DestroyCommand) Synopsis() string
Synopsis satisfies the Synopsis function of the cli.Command interface.
type DocGenerateCommand ¶
type DocGenerateCommand struct {
// contains filtered or unexported fields
}
func (DocGenerateCommand) Close ¶
func (c DocGenerateCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (DocGenerateCommand) GetExample ¶
func (c DocGenerateCommand) GetExample() string
func (DocGenerateCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*DocGenerateCommand) Run ¶
func (c *DocGenerateCommand) Run(args []string) int
type GenerateHelpCommand ¶
type GenerateHelpCommand struct {
// contains filtered or unexported fields
}
GenerateHelpCommand exists solely to provide top level help for the registry set of subcommands.
func (*GenerateHelpCommand) AutocompleteArgs ¶
func (c *GenerateHelpCommand) AutocompleteArgs() complete.Predictor
func (*GenerateHelpCommand) AutocompleteFlags ¶
func (c *GenerateHelpCommand) AutocompleteFlags() complete.Flags
func (GenerateHelpCommand) Close ¶
func (c GenerateHelpCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*GenerateHelpCommand) Flags ¶
func (c *GenerateHelpCommand) Flags() *flag.Sets
func (GenerateHelpCommand) GetExample ¶
func (c GenerateHelpCommand) GetExample() string
func (*GenerateHelpCommand) Help ¶
func (c *GenerateHelpCommand) Help() string
func (GenerateHelpCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*GenerateHelpCommand) Run ¶
func (c *GenerateHelpCommand) Run(args []string) int
func (*GenerateHelpCommand) Synopsis ¶
func (c *GenerateHelpCommand) Synopsis() string
type GeneratePackCommand ¶
type GeneratePackCommand struct {
// contains filtered or unexported fields
}
GeneratePackCommand adds a registry to the global cache.
func (*GeneratePackCommand) AutocompleteArgs ¶
func (c *GeneratePackCommand) AutocompleteArgs() complete.Predictor
func (*GeneratePackCommand) AutocompleteFlags ¶
func (c *GeneratePackCommand) AutocompleteFlags() complete.Flags
func (GeneratePackCommand) Close ¶
func (c GeneratePackCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*GeneratePackCommand) Flags ¶
func (c *GeneratePackCommand) Flags() *flag.Sets
func (GeneratePackCommand) GetExample ¶
func (c GeneratePackCommand) GetExample() string
func (*GeneratePackCommand) Help ¶
func (c *GeneratePackCommand) Help() string
func (GeneratePackCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*GeneratePackCommand) Run ¶
func (c *GeneratePackCommand) Run(args []string) int
func (*GeneratePackCommand) Synopsis ¶
func (c *GeneratePackCommand) Synopsis() string
type GenerateRegistryCommand ¶
type GenerateRegistryCommand struct {
// contains filtered or unexported fields
}
GenerateRegistryCommand adds a registry to the global cache.
func (*GenerateRegistryCommand) AutocompleteArgs ¶
func (c *GenerateRegistryCommand) AutocompleteArgs() complete.Predictor
func (*GenerateRegistryCommand) AutocompleteFlags ¶
func (c *GenerateRegistryCommand) AutocompleteFlags() complete.Flags
func (GenerateRegistryCommand) Close ¶
func (c GenerateRegistryCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*GenerateRegistryCommand) Flags ¶
func (c *GenerateRegistryCommand) Flags() *flag.Sets
func (GenerateRegistryCommand) GetExample ¶
func (c GenerateRegistryCommand) GetExample() string
func (*GenerateRegistryCommand) Help ¶
func (c *GenerateRegistryCommand) Help() string
func (GenerateRegistryCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*GenerateRegistryCommand) Run ¶
func (c *GenerateRegistryCommand) Run(args []string) int
func (*GenerateRegistryCommand) Synopsis ¶
func (c *GenerateRegistryCommand) Synopsis() string
type InfoCommand ¶
type InfoCommand struct {
// contains filtered or unexported fields
}
func (InfoCommand) Close ¶
func (c InfoCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*InfoCommand) Flags ¶
func (c *InfoCommand) Flags() *flag.Sets
func (InfoCommand) GetExample ¶
func (c InfoCommand) GetExample() string
func (*InfoCommand) Help ¶
func (c *InfoCommand) Help() string
func (InfoCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*InfoCommand) Run ¶
func (c *InfoCommand) Run(args []string) int
func (*InfoCommand) Synopsis ¶
func (c *InfoCommand) Synopsis() string
type JobStatusError ¶
type JobStatusError struct {
// contains filtered or unexported fields
}
JobStatusError encapsulates error information related to trying to retrieve status information about a running job.
type JobStatusInfo ¶
type JobStatusInfo struct {
// contains filtered or unexported fields
}
JobStatusInfo encapsulates status information about a running job.
type ListCommand ¶
type ListCommand struct {
// contains filtered or unexported fields
}
ListCommand lists all registries and pack that have been downloaded to the current machine.
func (*ListCommand) AutocompleteArgs ¶
func (c *ListCommand) AutocompleteArgs() complete.Predictor
func (*ListCommand) AutocompleteFlags ¶
func (c *ListCommand) AutocompleteFlags() complete.Flags
func (ListCommand) Close ¶
func (c ListCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*ListCommand) Flags ¶
func (c *ListCommand) Flags() *flag.Sets
func (ListCommand) GetExample ¶
func (c ListCommand) GetExample() string
func (*ListCommand) Help ¶
func (c *ListCommand) Help() string
func (ListCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*ListCommand) Run ¶
func (c *ListCommand) Run(args []string) int
func (*ListCommand) Synopsis ¶
func (c *ListCommand) Synopsis() string
type Option ¶
type Option func(c *baseConfig)
Option is used to configure Init on baseCommand.
func WithArgs ¶
WithArgs sets the arguments to the command that are used for parsing. Remaining arguments can be accessed using your flag set and asking for Args. Example: c.Flags().Args().
func WithClient ¶
WithClient configures the CLI to initialize a client.
func WithConfig ¶
WithConfig configures the CLI to find and load any project configuration. If optional is true, no error will be shown if a config can't be found.
func WithCustomArgs ¶
func WithCustomArgs(args []string, customValidation ValidationFn) Option
The same as WithArgs, but also assigns a custom validation function which will return an error if the custom validation criteria are not met. Only the function is assigned; acutal validation happens after the flags have been parsed.
func WithExactArgs ¶
The same as WithArgs, but also assigns the validation function ExactArgs which returns an error if exactly N args aren't provided. Only the function is assigned; actual validation happens after the flags have been parsed.
func WithFlags ¶
WithFlags sets the flags that are supported by this command. This MUST be set otherwise a panic will happen. This is usually set by just calling the Flags function on your command implementation.
func WithMaximumNArgs ¶
The same as WithArgs, but also assigns the validation function MaximumNArgs which returns an error if more than N args are provided. Only the function is assigned; actual validation happens after the flags have been parsed.
func WithMinimumNArgs ¶
The same as WithArgs, but also assigns the validation function MinimumNArgs which returns an error if fewer than N args are provided. Only the function is assigned; actual validation happens after the flags have been parsed.
func WithNoArgs ¶
The same as WithArgs, but also assigns the validation function NoArgs which returns an error if any args are provided. Only the function is assigned; actual validation happens after the flags have been parsed.
func WithNoConfig ¶
func WithNoConfig() Option
WithNoConfig configures the CLI to not expect any project configuration. This will not read any configuration files.
func WithSingleApp ¶
func WithSingleApp() Option
WithSingleApp configures the CLI to expect a configuration with one or more apps defined but a single app targeted with `-app`. If only a single app exists, it is implicitly the target. Zero apps is an error.
type PlanCommand ¶
type PlanCommand struct {
// contains filtered or unexported fields
}
func (*PlanCommand) AutocompleteArgs ¶
func (c *PlanCommand) AutocompleteArgs() complete.Predictor
func (*PlanCommand) AutocompleteFlags ¶
func (c *PlanCommand) AutocompleteFlags() complete.Flags
func (PlanCommand) Close ¶
func (c PlanCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*PlanCommand) Flags ¶
func (c *PlanCommand) Flags() *flag.Sets
func (PlanCommand) GetExample ¶
func (c PlanCommand) GetExample() string
func (*PlanCommand) Help ¶
func (c *PlanCommand) Help() string
func (PlanCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*PlanCommand) Run ¶
func (c *PlanCommand) Run(args []string) int
func (*PlanCommand) Synopsis ¶
func (c *PlanCommand) Synopsis() string
Synopsis satisfies the Synopsis function of the cli.Command interface.
type RegistryAddCommand ¶
type RegistryAddCommand struct {
// contains filtered or unexported fields
}
RegistryAddCommand adds a registry to the global cache.
func (*RegistryAddCommand) AutocompleteArgs ¶
func (c *RegistryAddCommand) AutocompleteArgs() complete.Predictor
func (*RegistryAddCommand) AutocompleteFlags ¶
func (c *RegistryAddCommand) AutocompleteFlags() complete.Flags
func (RegistryAddCommand) Close ¶
func (c RegistryAddCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RegistryAddCommand) Flags ¶
func (c *RegistryAddCommand) Flags() *flag.Sets
func (RegistryAddCommand) GetExample ¶
func (c RegistryAddCommand) GetExample() string
func (*RegistryAddCommand) Help ¶
func (c *RegistryAddCommand) Help() string
func (RegistryAddCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RegistryAddCommand) Run ¶
func (c *RegistryAddCommand) Run(args []string) int
func (*RegistryAddCommand) Synopsis ¶
func (c *RegistryAddCommand) Synopsis() string
type RegistryDeleteCommand ¶
type RegistryDeleteCommand struct {
// contains filtered or unexported fields
}
RegistryDeleteCommand deletes a registry from the global cache.
func (*RegistryDeleteCommand) AutocompleteArgs ¶
func (c *RegistryDeleteCommand) AutocompleteArgs() complete.Predictor
func (*RegistryDeleteCommand) AutocompleteFlags ¶
func (c *RegistryDeleteCommand) AutocompleteFlags() complete.Flags
func (RegistryDeleteCommand) Close ¶
func (c RegistryDeleteCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RegistryDeleteCommand) Flags ¶
func (c *RegistryDeleteCommand) Flags() *flag.Sets
func (RegistryDeleteCommand) GetExample ¶
func (c RegistryDeleteCommand) GetExample() string
func (*RegistryDeleteCommand) Help ¶
func (c *RegistryDeleteCommand) Help() string
func (RegistryDeleteCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RegistryDeleteCommand) Run ¶
func (c *RegistryDeleteCommand) Run(args []string) int
func (*RegistryDeleteCommand) Synopsis ¶
func (c *RegistryDeleteCommand) Synopsis() string
type RegistryHelpCommand ¶
type RegistryHelpCommand struct {
// contains filtered or unexported fields
}
RegistryHelpCommand exists solely to provide top level help for the registry set of subcommands.
func (*RegistryHelpCommand) AutocompleteArgs ¶
func (c *RegistryHelpCommand) AutocompleteArgs() complete.Predictor
func (*RegistryHelpCommand) AutocompleteFlags ¶
func (c *RegistryHelpCommand) AutocompleteFlags() complete.Flags
func (RegistryHelpCommand) Close ¶
func (c RegistryHelpCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RegistryHelpCommand) Flags ¶
func (c *RegistryHelpCommand) Flags() *flag.Sets
func (RegistryHelpCommand) GetExample ¶
func (c RegistryHelpCommand) GetExample() string
func (*RegistryHelpCommand) Help ¶
func (c *RegistryHelpCommand) Help() string
func (RegistryHelpCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RegistryHelpCommand) Run ¶
func (c *RegistryHelpCommand) Run(args []string) int
func (*RegistryHelpCommand) Synopsis ¶
func (c *RegistryHelpCommand) Synopsis() string
type RegistryListCommand ¶
type RegistryListCommand struct {
// contains filtered or unexported fields
}
RegistryListCommand lists all registries and pack that have been downloaded to the current machine.
func (*RegistryListCommand) AutocompleteArgs ¶
func (c *RegistryListCommand) AutocompleteArgs() complete.Predictor
func (*RegistryListCommand) AutocompleteFlags ¶
func (c *RegistryListCommand) AutocompleteFlags() complete.Flags
func (RegistryListCommand) Close ¶
func (c RegistryListCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RegistryListCommand) Flags ¶
func (c *RegistryListCommand) Flags() *flag.Sets
func (RegistryListCommand) GetExample ¶
func (c RegistryListCommand) GetExample() string
func (*RegistryListCommand) Help ¶
func (c *RegistryListCommand) Help() string
func (RegistryListCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RegistryListCommand) Run ¶
func (c *RegistryListCommand) Run(args []string) int
func (*RegistryListCommand) Synopsis ¶
func (c *RegistryListCommand) Synopsis() string
type RenderCommand ¶
type RenderCommand struct {
// contains filtered or unexported fields
}
RenderCommand is a command that allows users to render the templates within a pack and display them on the console. This is useful when developing or debugging packs.
func (*RenderCommand) AutocompleteArgs ¶
func (c *RenderCommand) AutocompleteArgs() complete.Predictor
func (*RenderCommand) AutocompleteFlags ¶
func (c *RenderCommand) AutocompleteFlags() complete.Flags
func (RenderCommand) Close ¶
func (c RenderCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RenderCommand) Flags ¶
func (c *RenderCommand) Flags() *flag.Sets
func (RenderCommand) GetExample ¶
func (c RenderCommand) GetExample() string
func (*RenderCommand) Help ¶
func (c *RenderCommand) Help() string
Help satisfies the Help function of the cli.Command interface.
func (RenderCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RenderCommand) Run ¶
func (c *RenderCommand) Run(args []string) int
Run satisfies the Run function of the cli.Command interface.
func (*RenderCommand) Synopsis ¶
func (c *RenderCommand) Synopsis() string
Synopsis satisfies the Synopsis function of the cli.Command interface.
type RunCommand ¶
type RunCommand struct { Validation ValidationFn // contains filtered or unexported fields }
func (*RunCommand) AutocompleteArgs ¶
func (c *RunCommand) AutocompleteArgs() complete.Predictor
func (*RunCommand) AutocompleteFlags ¶
func (c *RunCommand) AutocompleteFlags() complete.Flags
func (RunCommand) Close ¶
func (c RunCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*RunCommand) Flags ¶
func (c *RunCommand) Flags() *flag.Sets
Flags defines the flag.Sets for the operation.
func (RunCommand) GetExample ¶
func (c RunCommand) GetExample() string
func (*RunCommand) Help ¶
func (c *RunCommand) Help() string
func (RunCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*RunCommand) Run ¶
func (c *RunCommand) Run(args []string) int
func (*RunCommand) Synopsis ¶
func (c *RunCommand) Synopsis() string
Synopsis satisfies the Synopsis function of the cli.Command interface.
type StatusCommand ¶
type StatusCommand struct {
// contains filtered or unexported fields
}
func (*StatusCommand) AutocompleteArgs ¶
func (c *StatusCommand) AutocompleteArgs() complete.Predictor
func (*StatusCommand) AutocompleteFlags ¶
func (c *StatusCommand) AutocompleteFlags() complete.Flags
func (StatusCommand) Close ¶
func (c StatusCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*StatusCommand) Flags ¶
func (c *StatusCommand) Flags() *flag.Sets
func (StatusCommand) GetExample ¶
func (c StatusCommand) GetExample() string
func (*StatusCommand) Help ¶
func (c *StatusCommand) Help() string
func (StatusCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*StatusCommand) Run ¶
func (c *StatusCommand) Run(args []string) int
func (*StatusCommand) Synopsis ¶
func (c *StatusCommand) Synopsis() string
type StopCommand ¶
type StopCommand struct { Validation ValidationFn // contains filtered or unexported fields }
func (*StopCommand) AutocompleteArgs ¶
func (c *StopCommand) AutocompleteArgs() complete.Predictor
func (*StopCommand) AutocompleteFlags ¶
func (c *StopCommand) AutocompleteFlags() complete.Flags
func (StopCommand) Close ¶
func (c StopCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*StopCommand) Flags ¶
func (c *StopCommand) Flags() *flag.Sets
func (StopCommand) GetExample ¶
func (c StopCommand) GetExample() string
func (*StopCommand) Help ¶
func (c *StopCommand) Help() string
func (StopCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*StopCommand) Run ¶
func (c *StopCommand) Run(args []string) int
func (*StopCommand) Synopsis ¶
func (c *StopCommand) Synopsis() string
Synopsis satisfies the Synopsis function of the cli.Command interface.
type ValidationFn ¶
func ExactArgs ¶
func ExactArgs(n int) ValidationFn
Returns an error if exactly N args aren't provided
func MaximumNArgs ¶
func MaximumNArgs(n int) ValidationFn
Returns an error if more than N args provided
func MinimumNArgs ¶
func MinimumNArgs(n int) ValidationFn
Returns an error if fewer than N args provided
type VersionCommand ¶
type VersionCommand struct {
// contains filtered or unexported fields
}
func (*VersionCommand) AutocompleteArgs ¶
func (c *VersionCommand) AutocompleteArgs() complete.Predictor
func (*VersionCommand) AutocompleteFlags ¶
func (c *VersionCommand) AutocompleteFlags() complete.Flags
func (VersionCommand) Close ¶
func (c VersionCommand) Close() error
Close cleans up any resources that the command created. This should be defered by any CLI command that embeds baseCommand in the Run command.
func (*VersionCommand) Flags ¶
func (c *VersionCommand) Flags() *flag.Sets
func (VersionCommand) GetExample ¶
func (c VersionCommand) GetExample() string
func (*VersionCommand) Help ¶
func (c *VersionCommand) Help() string
func (VersionCommand) Init ¶
Init initializes the command by parsing flags, parsing the configuration, setting up the project, etc. You can control what is done by using the options.
Init should be called FIRST within the Run function implementation. Many options will affect behavior of other functions that can be called later.
func (*VersionCommand) Run ¶
func (c *VersionCommand) Run(args []string) int
func (*VersionCommand) Synopsis ¶
func (c *VersionCommand) Synopsis() string
Source Files ¶
- args.go
- commands.go
- deps_help.go
- deps_vendor.go
- destroy.go
- formatters.go
- gen_cli_docs.go
- generate_help.go
- generate_pack.go
- generate_registry.go
- generate_varfile.go
- help.go
- helpers.go
- info.go
- list.go
- main.go
- option.go
- plan.go
- registry_add.go
- registry_delete.go
- registry_help.go
- registry_list.go
- render.go
- run.go
- status.go
- stop.go
- version.go