Skip to content

Instantly share code, notes, and snippets.

@lholmquist
Created September 8, 2016 19:17
Show Gist options
  • Save lholmquist/0382f71f15fdb39a856afb562a7fa401 to your computer and use it in GitHub Desktop.
Save lholmquist/0382f71f15fdb39a856afb562a7fa401 to your computer and use it in GitHub Desktop.
const spawn = require('child_process').spawn;
const cmd = 'sh';
const args = ['-c', 'node index.js'];
const options = {
env: process.env,
stdio: [0, 1, 2]
};
spawn(cmd, args, options);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment