run

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2015 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsShellSafe

func IsShellSafe(str string) bool

Returns true if str is shell-safe

func ShellEscape

func ShellEscape(strs ...string) string

func ShellEscapeWord

func ShellEscapeWord(str string) string

Types

type Cmd

type Cmd struct {
	Cmd exec.Cmd
}

func Command

func Command(command string, args ...string) *Cmd

func (*Cmd) Output

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

func (*Cmd) OutputLines

func (c *Cmd) OutputLines() ([]string, error)

func (*Cmd) OutputString

func (c *Cmd) OutputString() (string, error)

func (*Cmd) ReadFrom

func (c *Cmd) ReadFrom(r io.Reader) *Cmd

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) String

func (c *Cmd) String() string

func (*Cmd) Wait

func (c *Cmd) Wait() error

func (*Cmd) WriteTo

func (c *Cmd) WriteTo(w io.Writer) *Cmd

type CmdError

type CmdError struct {
	ExecError error
	Cmd       *Cmd
}

func (*CmdError) Error

func (err *CmdError) Error() string

Jump to

Keyboard shortcuts

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