Versions in this module Expand all Collapse all v1 v1.23.14 Apr 4, 2026 v1.23.13 Mar 26, 2026 Changes in this version + func NewExitError(exitErr exec.ExitError, cmd string, stdOut string, stdErr string, ...) error + func RedactSensitiveArgs(args []string, sensitiveDataMatch []string) []string + func RedactSensitiveData(msg string) string + func TestAbortSignalRetainsOutputError(t *testing.T) — darwin/amd64, linux/amd64 + type CmdTree struct + func (o *CmdTree) Kill() + func (o *CmdTree) Start() error + type CmdTreeOptions struct + Interactive bool + type CommandRunner interface + Run func(ctx context.Context, args RunArgs) (RunResult, error) + RunList func(ctx context.Context, commands []string, args RunArgs) (RunResult, error) + ToolInPath func(name string) error + func NewCommandRunner(opt *RunnerOptions) CommandRunner + type ExitError struct + Cmd string + ExitCode int + func (e *ExitError) Error() string + type RunArgs struct + Args []string + Cmd string + Cwd string + DebugLogging *bool + Env []string + Interactive bool + SensitiveData []string + StdIn io.Reader + StdOut io.Writer + Stderr io.Writer + UseShell bool + func NewRunArgs(cmd string, args ...string) RunArgs + func NewRunArgsWithSensitiveData(cmd string, args, sensitiveData []string) RunArgs + func (b RunArgs) AppendParams(params ...string) RunArgs + func (b RunArgs) WithCwd(cwd string) RunArgs + func (b RunArgs) WithDebugLogging(debug bool) RunArgs + func (b RunArgs) WithEnv(env []string) RunArgs + func (b RunArgs) WithInteractive(interactive bool) RunArgs + func (b RunArgs) WithShell(useShell bool) RunArgs + func (b RunArgs) WithStdErr(stdErr io.Writer) RunArgs + func (b RunArgs) WithStdIn(stdIn io.Reader) RunArgs + func (b RunArgs) WithStdOut(stdOut io.Writer) RunArgs + type RunResult struct + ExitCode int + Stderr string + Stdout string + func NewRunResult(code int, stdout, stderr string) RunResult + type RunnerOptions struct + DebugLogging bool + Stderr io.Writer + Stdin io.Reader + Stdout io.Writer