node-env-match
Utility to test the value of the NODE_ENV system variable.
Usage
Add node-env-match as a project dependency
$ npm install node-env-match --save
Require and use it is really simple
// Suppose you run your app with// NODE_ENV=simple-test var nodeEnvMatch = ; // you can use a string argument // => true // => false // or a regular expression // => true // => true // or array of strings/reg-exp// it returns true if at least one matches // => true // => false
You can see more examples in test/node-env-match file.
Test
$ npm test
License
MIT © Andrea Tarquini