Improved the scripts

This commit is contained in:
Markus Fleschutz
2021-01-28 07:54:49 +01:00
parent 3fbf0b9891
commit f350629396
2 changed files with 61 additions and 56 deletions

View File

@ -6,16 +6,16 @@
.NOTES Author: Markus Fleschutz / License: CC0
#>
function ListScripts { param([string]$Path)
write-progress "Reading $Path..."
$Table = import-csv "$Path"
function ListScripts { param([string]$FilePath)
write-progress "Reading $FilePath..."
$Table = import-csv "$FilePath"
foreach($Row in $Table) {
New-Object PSObject -Property @{
'Script' = "$($Row.Filename)"
'Description' = "$($Row.Description)"
}
}
write-progress -completed "Reading $Path..."
write-progress -completed "Reading $FilePath..."
write-output ""
write-output "($($Table.Count) PowerShell scripts total)"
}