package
0.0.4
Repository: https://github.com/sunproxy/sunfly.git
Documentation: pkg.go.dev

# Functions

AddTargetFunc adds a TargetFunc to the list of functions used to find targets that may be targeted by a Source.
ByAlias looks up a command by an alias.
Commands returns a map of all registered commands indexed by the alias they were registered with.
New returns a new Command using the name and description passed.
Register registers a command with its name and all aliases that it has.

# Variables

ErrInsufficientArgs is returned by argument parsing functions if it does not have sufficient arguments passed and is not optional.

# Structs

Command is a wrapper around a Runnable.
Line represents a command line holding command arguments that were passed upon the execution of the command.
Output holds the output of a command execution.
ParamInfo holds the information of a parameter in a Runnable.

# Interfaces

Enum is an interface for enum-type parameters.
Limiter may be implemented by a type also implementing Runnable to limit the sources that may run the command.
Parameter is an interface for a generic parameters.
Runnable represents a Command that may be ran by a Command source.
Source represents a source of a command execution.
SubCommand represents a subcommand that may be added as a static value that must be written.
Target represents the target of a command.

# Type aliases

TargetFunc is a function used to find Targets eligible for a command executed by a given Source.
Varargs is an argument type that may be used to capture all arguments that follow.