cmd

package
v0.0.59 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 9, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateRootCommand

func CreateRootCommand(version string) *cobra.Command

CreateRootCommand used to run only root command without config.

func InitCompletionCmd added in v0.0.50

func InitCompletionCmd(rootCmd *cobra.Command, cfg *config.Config) func(cfg *config.Config)

InitCompletionCmd intializes root 'completion' subcommand. config can be nil, so we adding more flags only when config is found. Returns reinit function which must be called when config is parsed.

func InitSelfCmd added in v0.0.55

func InitSelfCmd(rootCmd *cobra.Command, version string)

InitSelfCmd intializes root 'self' subcommand.

func InitSubCommands added in v0.0.50

func InitSubCommands(rootCmd *cobra.Command, conf *config.Config, showAll bool, out io.Writer)

initialize all commands dynamically from config.

func PrintHelpMessage added in v0.0.50

func PrintHelpMessage(cmd *cobra.Command) error

func PrintRootHelpMessage added in v0.0.58

func PrintRootHelpMessage(cmd *cobra.Command) error

func PrintVersionMessage added in v0.0.50

func PrintVersionMessage(cmd *cobra.Command) error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL