cmd

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2026 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version = func() string {
	if version != "" {
		return version
	}
	if info, ok := debug.ReadBuildInfo(); ok && info.Main.Version != "" && info.Main.Version != "(devel)" {
		return info.Main.Version
	}
	return "dev"
}()

Version returns the CLI version. Prefers ldflags, then Go module version from go install.

Functions

func BuildApp

func BuildApp(w io.Writer) *cli.Command

BuildApp creates the root CLI command with all subcommands.

func Execute

func Execute(args []string) error

Execute runs the CLI with os.Stdout as the output writer.

func ExecuteWithOutput

func ExecuteWithOutput(args []string, w io.Writer) error

ExecuteWithOutput runs the CLI with a custom output writer for testability.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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