mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-04-24 19:08:27 +02:00
Update list-weather.ps1
This commit is contained in:
parent
30440a72c2
commit
571c3b7e49
@ -26,6 +26,7 @@ function GetDescription([string]$text) {
|
|||||||
"Cloudy" { return "☁️ cloudy" }
|
"Cloudy" { return "☁️ cloudy" }
|
||||||
"Fog" { return "🌫 fog" }
|
"Fog" { return "🌫 fog" }
|
||||||
"Freezing fog" { return "🌫 freezing fog" }
|
"Freezing fog" { return "🌫 freezing fog" }
|
||||||
|
"Heavy rain" { return "💧 heavy rain ⚠️" }
|
||||||
"Heavy snow" { return "❄️ heavy snow ⚠️" }
|
"Heavy snow" { return "❄️ heavy snow ⚠️" }
|
||||||
"Light drizzle" { return "💧 light drizzle" }
|
"Light drizzle" { return "💧 light drizzle" }
|
||||||
"Light freezing rain" { return "💧 light freezing rain ⚠️" }
|
"Light freezing rain" { return "💧 light freezing rain ⚠️" }
|
||||||
@ -99,7 +100,7 @@ try {
|
|||||||
foreach($hourly in $weather.weather.hourly) {
|
foreach($hourly in $weather.weather.hourly) {
|
||||||
$hour = $hourly.time / 100
|
$hour = $hourly.time / 100
|
||||||
$tempC = $(($hourly.tempC.toString()).PadLeft(3))
|
$tempC = $(($hourly.tempC.toString()).PadLeft(3))
|
||||||
$precip = $hourly.precipMM
|
$precip = $($($hourly.precipMM).PadLeft(4))
|
||||||
$humidity = $(($hourly.humidity.toString()).PadLeft(3))
|
$humidity = $(($hourly.humidity.toString()).PadLeft(3))
|
||||||
$pressure = $hourly.pressure
|
$pressure = $hourly.pressure
|
||||||
$windSpeed = $(($hourly.windspeedKmph.toString()).PadLeft(2))
|
$windSpeed = $(($hourly.windspeedKmph.toString()).PadLeft(2))
|
||||||
|
Loading…
Reference in New Issue
Block a user