exec

package
v0.3.24 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: Apache-2.0 Imports: 12 Imported by: 3

Documentation

Index

Constants

View Source
const DEFAULT_CHANNEL_SIZE = 10

Variables

This section is empty.

Functions

This section is empty.

Types

type Command added in v0.1.59

type Command struct {
	Name           string
	Args           []string
	Dir            string
	Environment    map[string]string
	PseudoTerminal *Size
	ChannelSize    int
	// contains filtered or unexported fields
}

func NewCommand added in v0.1.59

func NewCommand() *Command

func (*Command) AddPath added in v0.1.59

func (self *Command) AddPath(key string, path string)

func (*Command) Start added in v0.1.59

func (self *Command) Start(context contextpkg.Context) (*Process, error)

func (*Command) Stop added in v0.1.59

func (self *Command) Stop(err error)

func (*Command) Wait added in v0.1.59

func (self *Command) Wait() error

type Process added in v0.1.59

type Process struct {
	Stdout chan []byte // receive from this
	Stderr chan []byte // receive from this
	// contains filtered or unexported fields
}

func (*Process) Close added in v0.1.59

func (self *Process) Close()

Must be called, otherwise there will be a goroutine leak!

func (*Process) Resize added in v0.1.59

func (self *Process) Resize(width uint, height uint)

func (*Process) Stdin added in v0.1.59

func (self *Process) Stdin(p []byte)

type Size added in v0.1.59

type Size struct {
	Width  uint
	Height uint
}

type Terminal added in v0.1.59

type Terminal struct {
	InitialSize *Size
	Resize      chan Size // receive from this
	// contains filtered or unexported fields
}

func NewTerminal added in v0.1.59

func NewTerminal() (*Terminal, error)

func (*Terminal) Close added in v0.1.59

func (self *Terminal) Close() error

Jump to

Keyboard shortcuts

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