Documentation ¶
Index ¶
Constants ¶
View Source
const ( STDOUT = 0 STDERR = 1 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cmd ¶
type Cmd struct { Command string Options []string Dir string Stdout io.Writer Stderr io.Writer CommandTimeout int }
func (*Cmd) RetryCommand ¶
RetryCommand retries the given command, with exponential backoff, maxing at 5 min, for numOfRetries times. Returns error if all retries fail, nil otherwise.
func (*Cmd) RetryCommandWithCallback ¶ added in v0.4.2
RetryCommandWithCallback retries the given command, with exponential backoff, maxing at 5 min, for numOfRetries times. After every failed attempt the passed in callback is called.
type Wrapper ¶
type Wrapper struct {
// contains filtered or unexported fields
}
Wrapper struct holds data for the wrapper around stdout & stderr.
func GetStdErr ¶
GetStdErr returns an io.Writer for exec with the defined prefix. Cannot be used with cmd.CombinedOutput().
Click to show internal directories.
Click to hide internal directories.