ExecCommand is a small platform specific wrapper around os/exec.Command
(name string, arg ...string)
| 9 | |
| 10 | // ExecCommand is a small platform specific wrapper around os/exec.Command |
| 11 | func ExecCommand(name string, arg ...string) (*Cmd, error) { |
| 12 | cmd := exec.Command(name, arg...) |
| 13 | var err error |
| 14 | cmd.Path, err = LookPath(name) |
| 15 | if err != nil { |
| 16 | return nil, err |
| 17 | } |
| 18 | cmd.Env = fetchEnvironment() |
| 19 | return newCmd(cmd), nil |
| 20 | } |
no test coverage detected