Last active
December 4, 2018 12:25
-
-
Save zavr-1/de54ab9488cc536c914b8d0382e9ca35 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { fork } from 'child_process' | |
const { stdout, stderr } = fork('.', [], { | |
stdio: 'pipe', | |
execArgv: [], // for when debugging | |
}).on('error', (error) => { | |
console.log(error) | |
}) | |
stdout.pipe(process.stdout) | |
stderr.pipe(process.stderr) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment