4 ms·
First time I hear about '--save' for uninstall, but it doesn't make a difference in my case because I always install many things, test them all at once, then '-
by gear54rus 9y ago
First time I hear about '--save' for uninstall, but it doesn't make a difference in my case because I always install many things, test them all at once, then '--save' what I need and 'rm -rf' the 'node_modules'. After that, 'npm i' gives me everything I need.
I still think this change is beyond stupid.
- cben 9y agoWhen you commit your changes, it's similarly easy to inspect package.json changes, and only commit the lines you want [1]. This change increases the chance that what you have working locally is reproducible from "source". IMHO that's a very important goal, while debate over convenience of omitting --save vs --no-save is superficial. Obviously there are 2 groups and one will be unhappy either way, but does that justify calling it "beyond stupid"? (I could maybe see that if you had actual data that 90% people want --no-save...) Also, seems you can config old default by `npm config set save false` (with the risk one day you'll work on another machine and be surprised by uncustomized defaults). https://twitter.com/maybekatz/status/859193277894991872 https://twitter.com/maybekatz/status/859193277894991872 Docs are lacking, following up on https://github.com/npm/npm/issues/5108 https://github.com/npm/npm/issues/5108 [1] If your commit flow doesn't make this a pleasant experience — e.g. command-line git IMHO doesn't — you deserve better tools. I can recommend `git citool` for start — old and ugly UI, but fast, portable, has keyboard shortcuts, also very convenient for amending.