parallel software install

This commit is contained in:
2025-06-09 17:12:21 +02:00
parent 76f28837c6
commit 831651df13

View File

@@ -390,15 +390,11 @@ if ($manufacturer -match "Dell") {
} }
# Install applications using WinGet # Install applications using WinGet
foreach ($app in $apps) { $apps | ForEach-Object -Parallel {
Write-Host "Installing $($app.Name)..." Write-Host "Installing $($_.Name)..."
Start-Process powershell -ArgumentList "-Command winget install --id $($app.Id) --silent --accept-package-agreements --accept-source-agreements" winget install --id $($_.Id) --silent --accept-package-agreements --accept-source-agreements
} } -ThrottleLimit 4
foreach ($app in $apps) {
Write-Host "Installing $($app.Name)..."
winget install --id $($app.Id) --silent --accept-package-agreements --accept-source-agreements
}
# Remove unwanted applications # Remove unwanted applications
foreach ($app in $delnow) { foreach ($app in $delnow) {