Skip to content

Instantly share code, notes, and snippets.

@devonwesley
Created March 8, 2017 23:51
Show Gist options
  • Save devonwesley/422cba6bc4c999bdc1afddee99697ace to your computer and use it in GitHub Desktop.
Save devonwesley/422cba6bc4c999bdc1afddee99697ace to your computer and use it in GitHub Desktop.
Run 'node process.js' in the same folder/directory that the file lives.
process.on('exit', code => {
console.log(`About to exit with code: ${code}`)
})
process.on('uncaughtException', err => {
console.error(err)
// comment line 9 out, then run the command in the
// description. Then comment it back in. and run that same command from
// the description again.
process.exit(1)
})
process.stdin.resume()
console.dog()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment