Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Exec = func(cmd *Cmd) (o []byte, d time.Duration, err error) { defer func(t time.Time) { d = time.Since(t) }(time.Now()) execCmd := exec.CommandContext(cmd.ctx, cmd.Args[0], cmd.Args[1:]...) astilog.Debugf("Executing %s", cmd) o, err = execCmd.CombinedOutput() return }
Exec executes a command
Functions ¶
Types ¶
type Cmd ¶
type Cmd struct { Args []string // contains filtered or unexported fields }
Cmd represents a command
type StdWriter ¶
type StdWriter struct {
// contains filtered or unexported fields
}
StdWriter represents an object capable of writing what's coming out of stdout or stderr
func NewStdWriter ¶
NewStdWriter creates a new StdWriter
Click to show internal directories.
Click to hide internal directories.