mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-11-09 01:25:04 +01:00
Update open-dashboards.ps1
This commit is contained in:
parent
f8159e0769
commit
48bd375632
@ -11,6 +11,7 @@ NAME,URL,
|
||||
"FlightRadar24","https://www.flightradar24.com/27.63,-6.98/3",
|
||||
"Earthquake Watch","https://www.arcgis.com/apps/dashboards/c8af9c5411814584b460cc87cb7c3780",
|
||||
"Live Cyber Threat Map","https://threatmap.checkpoint.com",
|
||||
"Live Traffic","https://www.msn.com/en-us/traffic?lvl=11&intent=roadClosures",
|
||||
"Netflix Top 10","https://www.netflix.com/tudum/top10/",
|
||||
"YouTube Music Charts","https://charts.youtube.com/",
|
||||
"Webcams","https://www.foto-webcam.eu",
|
||||
|
|
@ -2,11 +2,10 @@
|
||||
.SYNOPSIS
|
||||
Open web dashboards
|
||||
.DESCRIPTION
|
||||
This PowerShell script launches the web browser with tabs of 18 dashboard websites.
|
||||
This PowerShell script launches the Web browser with 20 tabs of popular dashboard websites.
|
||||
.EXAMPLE
|
||||
PS> ./open-dashboards.ps1
|
||||
⏳ (1/2) Reading Data/popular-dashboards.csv...
|
||||
⏳ (2/2) Launching web browser tabs with: Toggl Track · Google Calendar · CNN News...
|
||||
✅ Launching Web browser with 20 tabs showing: Toggl Track, Google Calendar, Google Mail, Google Keep, Google Photos, Google News, Outlook Mail, CNN News, GitHub Explore, FlightRadar24, Earthquake Watch, Live Cyber Threat Map, Live Traffic, Netflix Top 10, YouTube Music Charts, Webcams, Peak Zugspitze, Airport Salzburg, Windy Weather Radar, Windy Weather Temperatures, (Hint: execute './switch-tabs.ps1' for automated tab switching)
|
||||
...
|
||||
.LINK
|
||||
https://github.com/fleschutz/PowerShell
|
||||
@ -15,19 +14,17 @@
|
||||
#>
|
||||
|
||||
try {
|
||||
$stopWatch = [system.diagnostics.stopwatch]::startNew()
|
||||
Write-Host "⏳ (1/2) Reading Data/popular-dashboards.csv..."
|
||||
Write-Progress "⏳ Reading Data/popular-dashboards.csv..."
|
||||
$table = Import-CSV "$PSScriptRoot/../Data/popular-dashboards.csv"
|
||||
$numRows = $table.Length
|
||||
Write-Host "⏳ (2/2) Launching web browser tabs with: " -noNewline
|
||||
Write-Progress -completed "."
|
||||
Write-Host "✅ Launching Web browser with 20 tabs showing: " -noNewline
|
||||
foreach($row in $table) {
|
||||
Write-Host "$($row.NAME) · " -noNewline
|
||||
Write-Host "$($row.NAME), " -noNewline
|
||||
& "$PSScriptRoot/open-default-browser.ps1" "$($row.URL)"
|
||||
Start-Sleep -milliseconds 100
|
||||
}
|
||||
Write-Host ""
|
||||
[int]$elapsed = $stopWatch.Elapsed.TotalSeconds
|
||||
"✅ Opened $NumRows dashboards in $elapsed sec (Hint: use 'switch-tabs.ps1' to switch between the tabs automatically)"
|
||||
Write-Host "(Hint: execute './switch-tabs.ps1' for automated tab switching)"
|
||||
exit 0 # success
|
||||
} catch {
|
||||
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
Loading…
Reference in New Issue
Block a user