javascript - Node start script env not being set on Mac -
i have following seems work on windows (and linux far can tell):
package.json:
"scripts": { "test": "node_env=test || set \"node_env=test\"&& mocha **/*.test.js --reporter spec" }
but doesn't work on osx reason, tried doing node_env=test
doesn't work either, thoughts?
you need add export
before variable name, set
in windows:
"scripts": { "test": "export node_env=test || set \"node_env=test\" && mocha **/*.test.js --reporter spec" }
Comments
Post a Comment