-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE] Add ability to install only the packages in package.json without any of their dependencies #1216
Comments
npm If your bug is reproducible on If your issue was a feature request, please consider opening a new RRFC or RFC. If your issue was a question or other idea that was not CLI-specific, consider opening a discussion on our feedback repo Closing: This is an automated message. |
What
Add a flag to
npm install
that does not install any dev dependencies or production dependencies.Why
I use NPM to manage dependencies in Cordova/web apps. It allows me to organize and update things like FontAwesome, jQuery, Leaflet, and other useful JS/CSS projects that my apps use. However,
npm install
pulls down every single dependency those projects have, when all I need is the finished, minified files those projects ship in their NPM packages. I end up writingrm -rf
Bash scripts consisting of manually-updated lists of the dependencies that do literally nothing for me except waste space in packaged versions of my apps, then adding those scripts as steps in the build process. Just the other day, one of thoserm -rf
scripts broke because an NPM dependency was missing and I had to stop working for several hours while my home folder restored from a recent backup. Another time I had to restore a backup disk image of a Jenkins build slave VM for the exact same reason.I can't be the only person on the planet with this use case, and it can't possibly be a very difficult feature to add.
References
The text was updated successfully, but these errors were encountered: