exec

package
v0.2.196 Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2023 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = exec.ErrNotFound

Functions

func LookPath

func LookPath(file string) (string, error)

Types

type Cmd

type Cmd struct {
	Path   string
	Args   []string
	Env    []string
	Dir    string
	Stdin  io.Reader
	Stdout io.Writer
	Stderr io.Writer

	Process *os.Process // after Start

	// info about exited process, available after a call to Wait or Run:
	ProcessState *os.ProcessState
	// contains filtered or unexported fields
}

func Command

func Command(name string, arg ...string) *Cmd

func CommandContext

func CommandContext(ctx context.Context, name string, arg ...string) *Cmd

func (*Cmd) CombinedOutput

func (c *Cmd) CombinedOutput() ([]byte, error)

func (*Cmd) Environ

func (c *Cmd) Environ() []string

gocompiler: go1.19

func (*Cmd) Output

func (c *Cmd) Output() ([]byte, error)

func (*Cmd) Run

func (c *Cmd) Run() error

func (*Cmd) Start

func (c *Cmd) Start() error

func (*Cmd) StderrPipe

func (c *Cmd) StderrPipe() (io.ReadCloser, error)

func (*Cmd) StdinPipe

func (c *Cmd) StdinPipe() (io.WriteCloser, error)

func (*Cmd) StdoutPipe

func (c *Cmd) StdoutPipe() (io.ReadCloser, error)

func (*Cmd) Wait

func (c *Cmd) Wait() error

type Error

type Error = exec.Error

type ExitError

type ExitError = exec.ExitError

Jump to

Keyboard shortcuts

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