mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-03-26 14:26:10 +01:00
Updated list-scripts.ps1
This commit is contained in:
parent
3705f9c2dd
commit
d0de5af787
@ -15,14 +15,15 @@ function ListScripts { param([string]$FilePath)
|
||||
'Description' = "$($Row.Description)"
|
||||
}
|
||||
}
|
||||
$global:NumScripts = $Table.Count
|
||||
write-progress -completed "Reading $FilePath..."
|
||||
write-output ""
|
||||
write-output "($($Table.Count) PowerShell scripts total)"
|
||||
}
|
||||
|
||||
try {
|
||||
$PathToRepo = "$PSScriptRoot/.."
|
||||
ListScripts "$PathToRepo/Data/scripts.csv" | format-table -property Script, Description
|
||||
ListScripts "$PathToRepo/Data/scripts.csv" | format-table -property Script,Description
|
||||
|
||||
write-host -foregroundColor green "OK - $($global:NumScripts) PowerShell scripts total"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
Loading…
Reference in New Issue
Block a user