common

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FprintSubcommands

func FprintSubcommands(w io.Writer, cmdName string, subcommands []*CliCommand)

func ParseUint32Arg

func ParseUint32Arg(args *[]string) (uint32, exits.ExitCode, error)

Types

type CliCommand

type CliCommand struct {
	// contains filtered or unexported fields
}

func NewCliCommand

func NewCliCommand(
	name string,
	description string,
	argDescription string,
	handler func(args []string, conn *grpc.ClientConn) (exits.ExitCode, error),
) *CliCommand

func NewCliCommandWithFlags

func NewCliCommandWithFlags(
	name string,
	description string,
	argDescription string,
	handler func(args []string, conn *grpc.ClientConn) (exits.ExitCode, error),
	flagSetUp func(*flag.FlagSet),
) *CliCommand

func NewCliSubcommand

func NewCliSubcommand(name string, subcommands []*CliCommand) *CliCommand

func (*CliCommand) Execute

func (c *CliCommand) Execute(args []string, conn *grpc.ClientConn, cmdNameChain []string) exits.ExitCode

Jump to

Keyboard shortcuts

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