cmd

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2018 License: AGPL-3.0 Imports: 43 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Success is the same as EXIT_SUCCESS in C
	Success = iota

	// BadArgs passed to cli; not our fault.
	BadArgs

	// BadPassword passed to prompt or switch; not our fault.
	BadPassword

	// DaemonNotResponding means the daemon does not respond in timely fashion.
	// Probably our fault.
	DaemonNotResponding

	// UnknownError is an uncategorized error, probably our fault.
	UnknownError
)

Variables

This section is empty.

Functions

func RunCmdline

func RunCmdline(args []string) int

RunCmdline starts a brig commandline tool.

func TranslateHelp

func TranslateHelp(cmds []cli.Command) []cli.Command

TranslateHelp fills in the usage and description for each command. This is separated from the command definition to make things more readable, and separate logic from the (lengthy) documentation.

Types

type ExitCode

type ExitCode struct {
	Code    int
	Message string
}

ExitCode is an error that maps the error interface to a specific error message and a unix exit code

func (ExitCode) Error

func (err ExitCode) Error() string

Directories

Path Synopsis
pwd
Package tabwriter implements a write filter (tabwriter.Writer) that translates tabbed columns in input into properly aligned text.
Package tabwriter implements a write filter (tabwriter.Writer) that translates tabbed columns in input into properly aligned text.

Jump to

Keyboard shortcuts

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