We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ead947f commit ff6463fCopy full SHA for ff6463f
Setup.ps1
@@ -587,8 +587,17 @@ function Setup {
587
elseif (Get-Command npm -ErrorAction SilentlyContinue) {
588
Write-PrettyTitle "Install NPM Global Packages"
589
foreach ($package in $npmPackages) {
590
- npm install --global --silent $package
591
- Write-PrettyOutput -p "npm" -e "$package" -m "installed."
+ $cmd = $package.Command
+ $packages = $package.Packages
592
+ if (!(Get-Command $cmd -ErrorAction SilentlyContinue)) {
593
+ foreach ($pkg in $packages) {
594
+ npm install --global --silent $pkg
595
+ Write-PrettyOutput -p "npm" -e "$pkg" -m "installed."
596
+ }
597
598
+ else {
599
+ Write-PrettyOutput -p "npm" -e "$cmd" -m "already installed."
600
601
}
602
603
0 commit comments