ExecTimeoutEnv is the same as ExecTimeout but allows appending additional environment variables to the child process. Pass nil for env to inherit the parent process environment unchanged.
(timeout time.Duration, env []string, desc, cmdName string, args ...string)
| 127 | // environment variables to the child process. Pass nil for env to inherit the |
| 128 | // parent process environment unchanged. |
| 129 | func ExecTimeoutEnv(timeout time.Duration, env []string, desc, cmdName string, args ...string) (string, string, error) { |
| 130 | return ExecDirEnv(timeout, "", env, desc, cmdName, args...) |
| 131 | } |
| 132 | |
| 133 | // Exec starts executing a shell command, it tracks corresponding its process and use default timeout. |
| 134 | func Exec(desc, cmdName string, args ...string) (string, string, error) { |
no test coverage detected