* Execs a given command with the specified arguments inside a shell. All process stdout * output is captured and returned as resolution on completion. Depending on the chosen * output mode, stdout/stderr output is also printed to the console, or only on error. * * @returns a Promise reso
(command: string, options: ExecOptions = {})
| 143 | * rejects on command failure. |
| 144 | */ |
| 145 | static exec(command: string, options: ExecOptions = {}): Promise<SpawnResult> { |
| 146 | const env = getEnvironmentForNonInteractiveCommand(options.env); |
| 147 | return processAsyncCmd(command, options, _exec(command, {...options, env})); |
| 148 | } |
| 149 | } |
| 150 | |
| 151 | /** |
nothing calls this directly
no test coverage detected