Created
January 29, 2014 17:36
-
-
Save TravelingTechGuy/8692935 to your computer and use it in GitHub Desktop.
Update (global) NPM repositories, and show which repositories were updated by comparing version numbers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm -g ls --depth=0 > ~/before.txt | |
npm -g update > /dev/null 2>&1 | |
npm -g ls --depth=0 > ~/after.txt | |
diff -as ~/before.txt ~/after.txt | |
rm ~/before.txt ~/after.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Options to change this script:
-g
from lines 1-3, if you want to update a local projectnpm -g update
, to get verbose update output-s
parameter from line 4, to not receive the"files are identical"
message~
with the desired path