Documentation
¶
Overview ¶
Package cmd provides command-line interface commands for the application. It defines a registry of commands categorized by their application modules. This package leverages the github.com/urfave/cli/v2 library for CLI interactions.
Index ¶
- func AddCommand(name string, commands []*cli.Command) bool
- func AddCommands(commands map[string][]*cli.Command) bool
- func GetAclCommands() []*cli.Command
- func GetCommands() map[string][]*cli.Command
- func GetDatasetCommands() []*cli.Command
- func GetGeneratorCommands() []*cli.Command
- func GetIndexerCommands() []*cli.Command
- func GetLoaderCommands() []*cli.Command
- func GetMigrationCommands() []*cli.Command
- func GetRegisteredCommands() []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddCommand ¶
AddCommand adds a single CLI command to the registry under a specified module name. If the module name does not exist in the current registry, the commands are added. If the module name exists, the commands are appended to the existing slice. Returns true if the commands are added successfully, false if the commands are not added because the module name already exists.
func AddCommands ¶
AddCommands adds a map of CLI commands to the existing registry. The function iterates over the provided commands map and uses AddCommand to add each command under the specified module name. Returns true if all commands are added successfully, otherwise returns false.
func GetAclCommands ¶
func GetAclCommands() []*cli.Command
func GetCommands ¶
func GetCommands() map[string][]*cli.Command
GetCommands returns the complete registry of CLI commands. This function provides access to all the registered commands for different modules of the application. It is typically used to initialize the CLI application with all the necessary commands.
func GetDatasetCommands ¶
func GetDatasetCommands() []*cli.Command
GetDatasetCommands returns a list of CLI commands for managing database exports and imports.
func GetGeneratorCommands ¶
func GetGeneratorCommands() []*cli.Command
func GetIndexerCommands ¶
func GetIndexerCommands() []*cli.Command
func GetLoaderCommands ¶
func GetLoaderCommands() []*cli.Command
func GetMigrationCommands ¶
func GetMigrationCommands() []*cli.Command
func GetRegisteredCommands ¶
func GetRegisteredCommands() []string
GetRegisteredCommands retrieves a slice of all registered module names. This is helpful for determining which modules have been initialized and are available for interaction via the CLI.
Types ¶
This section is empty.