cmd

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2026 License: MIT Imports: 36 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute()

Types

type AgentContext added in v0.5.0

type AgentContext struct {
	Name        string    `json:"name"`
	Version     string    `json:"version"`
	Commit      string    `json:"commit"`
	Short       string    `json:"short"`
	Long        string    `json:"long"`
	GlobalFlags []Flag    `json:"globalFlags"`
	Commands    []Command `json:"commands"`
}

type Command added in v0.5.0

type Command struct {
	Name       string       `json:"name"`
	Path       []string     `json:"path"`
	Use        string       `json:"use"`
	Short      string       `json:"short"`
	Long       string       `json:"long"`
	Hidden     bool         `json:"hidden"`
	Runnable   bool         `json:"runnable"`
	Args       []Positional `json:"args"`
	Flags      []Flag       `json:"flags"`
	FlagGroups FlagGroups   `json:"flagGroups"`
	Commands   []Command    `json:"commands"`
}

type Flag added in v0.5.0

type Flag struct {
	Name        string `json:"name"`
	Shorthand   string `json:"shorthand"`
	Type        string `json:"type"`
	Default     string `json:"default"`
	Description string `json:"description"`
	Required    bool   `json:"required"`
	Persistent  bool   `json:"persistent"`
}

type FlagGroups added in v0.5.0

type FlagGroups struct {
	OneRequired       [][]string `json:"oneRequired"`
	MutuallyExclusive [][]string `json:"mutuallyExclusive"`
	RequiredTogether  [][]string `json:"requiredTogether"`
}

type Positional added in v0.5.0

type Positional struct {
	Name     string `json:"name"`
	Required bool   `json:"required"`
}

type Result

type Result struct {
	Success bool   `json:"success"`
	Message string `json:"message,omitempty"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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