Node in the middle. Intercept calls to the node binary and set some node specific flags before running a program
MIT License
Node in the middle. Intercept calls to the node
binary and set some node specific
flags before running a program
npm install nitm
Useful if you need to profile another application but don't know when it is invoking node itself.
Tested on Mac, Linux, and Windows
var nitm = require('nitm')
// set --no-warnings to node when tape invokes it.
nitm(['--no-warnings'], ['tape', 'test/*.js'], {stdio: 'inherit'})
var proc = nitm(flags, command, [options])
Run a command but intercept calls to node and set the specified flags.
Returns a child process instance. Options are forwarded to childProcess.spawn
.
There is a cli available as well
npm i -g nitm
# flags before -- and your program after
nitm --no-warnings -- tape test/*.js
This project was kindly sponsored by nearForm.
MIT