Skip to content

Instantly share code, notes, and snippets.

@isaacs
Created September 17, 2011 06:00
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 isaacs/1223672 to your computer and use it in GitHub Desktop.
Save isaacs/1223672 to your computer and use it in GitHub Desktop.
var ch = require("child_process")
, cp = ch.spawn("node", ["-v"])
cp.on("exit", function (code) {
console.error("exit", code)
})
cp.stdout.pipe(process.stdout)
cp.stderr.pipe(process.stderr)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment