subcommands

package
v0.27.3 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2021 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

View Source
const CopyCommand = "cp"
View Source
const DecodeScriptCommand = "decode-script"

Variables

This section is empty.

Functions

func Process

func Process(args []string) error

Process takes the set of arguments passed to entrypoint and executes any subcommand that the args call for. An error is returned to the caller to indicate that a subcommand was matched and to pass back its success/fail state. The returned error will be nil if no subcommand was matched to the passed args, SubcommandSuccessful if args matched and the subcommand succeeded, or any other error if the args matched but the subcommand failed.

Types

type SubcommandError

type SubcommandError struct {
	// contains filtered or unexported fields
}

func (SubcommandError) Error

func (err SubcommandError) Error() string

type SubcommandSuccessful

type SubcommandSuccessful struct {
	// contains filtered or unexported fields
}

func (SubcommandSuccessful) Error

func (err SubcommandSuccessful) Error() string

Jump to

Keyboard shortcuts

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