pipe output to current process stdout.
await spawn('sam', '--help') Copy
await spawn('sam', '--help')
capture output
const stdout = String(await spawn('git', ['rev-parse', 'HEAD'], { shell: true })) Copy
const stdout = String(await spawn('git', ['rev-parse', 'HEAD'], { shell: true }))
Example
pipe output to current process stdout.
capture output