commit fc855af1e816ead1bd4d12c8cdb4d94cfc710f25
parent b688719e11c9bef3c5e253929e868b7228419583
Author: Alex Balgavy <alex@balgavy.eu>
Date: Sat, 27 Feb 2021 14:55:37 +0100
updatemaster: misc improvements
Diffstat:
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/scripts/updatemaster b/scripts/updatemaster
@@ -39,7 +39,7 @@ class Homebrew
warn 'Only numbers allowed'
exit 1
end
- start_sudo_cache
+ start_sudo_cache unless @to_upgrade.empty?
end
def do_upgrade
@@ -119,12 +119,7 @@ class NPM
def do_upgrade
outdated = `npm outdated -g --parseable | sed 's!:.*!!g; s!.*/!!'`.split
outdated.each { |pkg| system "npm -g install #{pkg}@latest" }
- system 'npm -g update'
- end
-
- def cleanup
- system 'npm -g dedupe'
- system 'npm -g prune'
+ system 'npm -g upgrade'
end
end