Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Runner ¶
type Runner interface {
// Run executes a command, returning combined output and error.
Run(name string, args ...string) ([]byte, error)
// RunAttached executes a command with stdin/stdout/stderr attached to the terminal.
RunAttached(name string, args ...string) error
// RunBackground starts a command detached from the terminal and returns immediately.
// Stdin/stdout/stderr are connected to /dev/null.
RunBackground(name string, args ...string) error
// LookPath checks if a binary is in PATH.
LookPath(name string) (string, error)
}
Runner executes system commands. Mockable for tests.
type SystemRunner ¶
type SystemRunner struct{}
SystemRunner executes real system commands.
func (*SystemRunner) RunAttached ¶
func (r *SystemRunner) RunAttached(name string, args ...string) error
func (*SystemRunner) RunBackground ¶
func (r *SystemRunner) RunBackground(name string, args ...string) error
Click to show internal directories.
Click to hide internal directories.