bashrunner

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BashRunner

type BashRunner struct {
	// contains filtered or unexported fields
}

func NewBashRunner

func NewBashRunner(opts ...Option) *BashRunner

NewBashRunner creates a new BashRunner instance

func (*BashRunner) Run

func (br *BashRunner) Run(script string, envVars map[string]string) (runner.ScriptResult, error)

type MockRunner

type MockRunner struct {
	Result runner.ScriptResult
	Error  error
}

MockRunner implements Runner interface for testing

func (*MockRunner) Run

func (m *MockRunner) Run(script string, envVars map[string]string) (runner.ScriptResult, error)

Run implements the Runner interface for MockRunner

type Option

type Option func(*BashRunner)

func WithTempDir

func WithTempDir(dir string) Option

WithTempDir sets a custom temporary directory

Jump to

Keyboard shortcuts

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