shell

package
v0.0.0-...-5720ada Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder interface {
	WithOSEnv() Builder
	WithEnv(env Env) Builder
	WithWorkingDir(dir string) Builder
	WithSysProcAttr(attr *syscall.SysProcAttr) Builder
	WithContextCancellation(gracefulTimeout time.Duration) Builder
	Prepare() Supervisor
}

func NewBuilder

func NewBuilder(ctx context.Context, path string, args ...string) Builder

func NewDefaultBuilder

func NewDefaultBuilder(ctx context.Context, path string, args ...string) Builder

type Env

type Env map[string]string

type Supervisor

type Supervisor interface {
	logger.Loggable

	Cmd() *exec.Cmd
	Start() error
	Run() error
	RunAndGetOutput() ([]byte, []byte, error)
	Wait() error
	Kill(signal syscall.Signal) error
}

func New

func New(ctx context.Context, path string, args ...string) Supervisor

Jump to

Keyboard shortcuts

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