mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-12-16 11:40:53 +01:00
Update open-dashboards.ps1
This commit is contained in:
parent
4408b5157a
commit
1eba16843f
@ -13,13 +13,17 @@
|
||||
|
||||
try {
|
||||
$stopWatch = [system.diagnostics.stopwatch]::startNew()
|
||||
Write-Progress "⏳ Opening Web dashboards in your browser..."
|
||||
Write-Progress "⏳ Loading Data/popular-dashboards.csv..."
|
||||
$Table = Import-CSV "$PSScriptRoot/../Data/popular-dashboards.csv"
|
||||
$NumRows = $Table.Length
|
||||
foreach($Row in $Table) {
|
||||
& "$PSScriptRoot/open-default-browser.ps1" "$Row.URL"
|
||||
$Name = $Row.NAME
|
||||
$URL = $Row.URL
|
||||
Write-Progress "⏳ Opening $Name in your browser..."
|
||||
& "$PSScriptRoot/open-default-browser.ps1" "$URL"
|
||||
Start-Sleep -milliseconds 100
|
||||
}
|
||||
Write-Progress -completed "."
|
||||
[int]$elapsed = $stopWatch.Elapsed.TotalSeconds
|
||||
"✅ Opened $NumRows Web dashboards in $elapsed sec (use switch-tabs.ps1 to switch the tabs automatically)"
|
||||
exit 0 # success
|
||||
|
Loading…
Reference in New Issue
Block a user