`npm install` is executed regardless of node_env
See original GitHub issueI would prefer something like this in the post process hook:
NODE_ENV={{node_env}} npm install
If you agree, I will create a (tested) PR
Issue Analytics
- State:
- Created 8 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
env variable NODE_ENV=production effect on npm install is ...
To install dev dependencies, npm --production=false install will work even with NODE_ENV=production . Or you can run NODE_ENV=development npm ...
Read more >npm install won't install devDependencies - Stack Overflow
For my build to run properly I was not allowed to change the value of NODE_ENV so I forced npm to install all...
Read more >node-env-run - npm
node-env -run. Command-line tool to read .env files and execute scripts/commands after loading those environment variables. Uses dotenv ...
Read more >NODE_ENV is always "development" regardless of my secrets ...
The command I'm using to start the server in my Dockerfile is CMD ["npm", "run", "start"] and in my package.json's script section I...
Read more >Node.js Everywhere with Environment Variables! - Medium
Create an empty folder named env-playground . Then create a file named server.js and add the code above to it. Now when you...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
With the --production flag (or when the NODE_ENV environment variable is set to production), npm will not install modules listed in devDependencies. (https://docs.npmjs.com/cli/install)
and that is cool 😉
I’m working on other things right now, but it is still on my agenda…