Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Alias ¶
type Alias struct {
// Use sets the command's Use field (required)
Use string
// Example optionally replaces the command's Example field (empty preserves original)
Example string
// Command is a factory function that creates the target command
Command func(*cmdutil.Factory) *cobra.Command
}
Alias defines a top-level command alias to a subcommand. This follows Docker's pattern where `docker run` is an alias for `docker container run`. Each alias creates a new command instance from the factory, overriding only Use and optionally Example, while inheriting all other properties (flags, RunE, etc.).
Click to show internal directories.
Click to hide internal directories.