# Functions
DirectStreams returns the underlying io.Writer to directly stream to stdout and stderr.
ExitWhenParentProcessEnds waits until the controlling parent process ends and then exits the current process.
Fatal outputs the errorMsg and exits with status exitCode.
FatalError outputs the error and exits with status exitCode.
FatalResult outputs the result and exits with status exitCode.
GetFormat returns the output format currently set.
InputUserField prompts the user to input the provided user field.
InteractiveStreams returns the underlying io.Reader and io.Writer to directly stream to stdin and stdout.
NewBufferedStreams returns a pair of io.Writer to buffer the command output.
NewCommand creates a new `feedback` command.
NewDownloadProgressBarCB creates a progress bar callback that outputs a progress bar on the terminal.
NewTaskProgressCB returns a commands.TaskProgressCB progress listener that outputs to terminal.
OutputStreams returns a pair of io.Writer to write the command output.
ParseOutputFormat parses a string and returns the corresponding OutputFormat.
Print behaves like fmt.Print but writes on the out writer and adds a newline.
Printf behaves like fmt.Printf but writes on the out writer and adds a newline.
PrintResult is a convenient wrapper to provide feedback for complex data, where the contents can't be just serialized to JSON but requires more structure.
ProgressBar returns a DownloadProgressCB that prints a progress bar.
SetErr can be used to change the err writer at runtime.
SetFormat can be used to change the output format at runtime.
SetOut can be used to change the out writer at runtime.
TaskProgress returns a TaskProgressCB that prints the task progress.
Warning outputs a warning message.
# Constants
ErrBadArgument is returned when the arguments are not valid (7).
ErrCoreConfig represents an error in the cli core config, for example some basic files shipped with the installation are missing, or cannot create or get basic directories vital for the CLI to work.
ErrGeneric Generic error (1 is the reserved "catchall" code in Unix).
ErrNetwork is returned when a network error occurs (5).
ErrNoConfigFile is returned when the config file is not found (3).
JSON format.
MinifiedJSON format.
Success (0 is the no-error return code in Unix).
Text is the plain text format, suitable for interactive terminals.
YAML format.
# Structs
OutputStreamsResult contains the accumulated stdout and stderr output when the selected output format is not Text.
# Interfaces
ErrorResult is a result embedding also an error.
Result is anything more complex than a sentence that needs to be printed for the user.