Documentation
¶
Index ¶
- Variables
- func Command(name string, arg ...string) *exec.Cmd
- func CommandContext(ctx context.Context, name string, arg ...string) *exec.Cmd
- func KillCommand(cmd *exec.Cmd) error
- func LookPath(file string) (string, error)
- func TerminateCommand(cmd *exec.Cmd, sig os.Signal) error
- type Cmd
- type Error
- type Exec
- type ExitError
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrDot = exec.ErrDot ErrNotFound = exec.ErrNotFound ErrWaitDelay = exec.ErrWaitDelay )
Variable aliases for os/exec variables.
Functions ¶
func CommandContext ¶
CommandContext returns *os/exec.Cmd with Setpgid = true When ctx canceled, `github.com/k1LoW/exec.CommandContext` send signal to process group.
func KillCommand ¶
KillCommand send syscall.SIGKILL to cmd.Process.Pid process group KillCommand send taskkill to cmd.Process.Pid ( if runtime.GOOS == 'windows' ).
Types ¶
Click to show internal directories.
Click to hide internal directories.