Skip to content

Instantly share code, notes, and snippets.

@AvianFlu
Last active October 31, 2020 20:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AvianFlu/575117a3322f87d4a19d to your computer and use it in GitHub Desktop.
Save AvianFlu/575117a3322f87d4a19d to your computer and use it in GitHub Desktop.
var spawn = require('child_process').spawn,
waitpid = require('waitpid');
var termynull = spawn(process.argv[2], process.argv.slice(3), {
stdio: 'inherit'
});
var r = waitpid(termynull.pid);
termynull.on('exit', function (code) {
console.log('TermyNull exited with code %d', code);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment