Update install-basic-apps.ps1

This commit is contained in:
Markus Fleschutz 2023-04-27 17:35:58 +02:00
parent ac3d34b63e
commit e2a99ce4aa

View File

@ -15,7 +15,7 @@
try { try {
$StopWatch = [system.diagnostics.stopwatch]::startNew() $StopWatch = [system.diagnostics.stopwatch]::startNew()
"Step 1 - Loading Data/basic-apps.csv..." "(1/30) Loading Data/basic-apps.csv..."
$Table = Import-CSV "$PSScriptRoot/../Data/basic-apps.csv" $Table = Import-CSV "$PSScriptRoot/../Data/basic-apps.csv"
$NumEntries = $Table.count $NumEntries = $Table.count
Write-Host " The following $NumEntries basic apps will be installed or upgraded: " -NoNewline Write-Host " The following $NumEntries basic apps will be installed or upgraded: " -NoNewline
@ -41,7 +41,7 @@ try {
} }
[int]$Installed = ($NumEntries - $Failed) [int]$Installed = ($NumEntries - $Failed)
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds [int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
"✔️ installed $Installed basic apps in $Elapsed sec. ($Failed failed)" "✔️ installed $Installed of $NumEntries basic apps in $Elapsed sec"
exit 0 # success exit 0 # success
} catch { } catch {
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])" "⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"