shell

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Environ

func Environ() []string

func ExitCode

func ExitCode(result Result) int

func GetError

func GetError(result Result) []byte

func GetOutput

func GetOutput(result Result) []byte

func Getenv

func Getenv(key string) string

func Output added in v0.0.2

func Output(name string, args ...string) (string, error)

func Run added in v0.0.8

func Run(cmd string) (string, error)

func Setenv

func Setenv(key string, value string) error

func Success

func Success(result Result) bool

func Unsetenv

func Unsetenv(key string) error

func Which

func Which(name string) bool

Types

type Command

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

func Dir

func Dir(cmd Command, path string) Command

func Env

func Env(cmd Command, key string, value string) Command

func New

func New(name string, args ...string) Command

func SetTimeout

func SetTimeout(cmd Command, seconds int) Command

type Result

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

func Execute

func Execute(cmd Command) Result

Jump to

Keyboard shortcuts

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