shell

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const OsWindows = "windows"

OsWindows is windows os name

Variables

This section is empty.

Functions

func FormatExitError

func FormatExitError(err error) error

FormatExitError extracts process wait error and formats it

func KillProcessGroup added in v0.4.0

func KillProcessGroup(cmd *exec.Cmd) error

KillProcessGroup kills process group created by parent process

func PrepareCommand

func PrepareCommand(cmdName string) *exec.Cmd

PrepareCommand prepares a command to execute

Types

type Environment

type Environment map[string]string

Environment is map of predefined scope variables

func (Environment) Empty

func (e Environment) Empty() bool

Empty checks if predefined vars list is empty

func (Environment) ToArray

func (e Environment) ToArray(defaults ...string) (arr []string)

ToArray returns array of variables usable for exec.Cmd

Jump to

Keyboard shortcuts

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