modulepackage
0.0.0-20220424020042-903ec0a22253
Repository: https://github.com/edufschmidt/go-cli.git
Documentation: pkg.go.dev
# README
go-cli
An easy-to-use package for building CLI apps in Go. It's heavily based on mitchellh/cli, with modifications that make it even simpler.
# Packages
No description provided by the author
# Functions
Default CLI configurations.
DefaultHelpFunc is the default function for generating help output.
New returns a new CLI instance with sensible defaults.
NewRouter creates a new router.
# Constants
No description provided by the author
# Structs
Args contains parsed input to the CLI.
CLI contains the state necessary to run subcommands and parse the command line arguments.
CLI configurations.
MockCommand is an implementation of Command that can be used for testing and for automatically populating missing parent commands.
Router is used to resolve names into commands.
BasicUI is an implementation of UI that outputs to the given writer.
# Interfaces
A Command is a runnable sub-command of a CLI.
A NamedCommand is a runnable sub-command of a CLI with a name.
UI is an interface for interacting with the terminal, or "interface" of a CLI.
# Type aliases
HelpFunc is the type of the function that is responsible for generating the help output when the CLI must show the general help text.