mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-11-25 09:23:12 +01:00
Update write-date.ps1 and list-weather.ps1
This commit is contained in:
parent
ba0e42470b
commit
7ab84e960d
@ -95,9 +95,13 @@ try {
|
|||||||
if ($Day -eq 0) {
|
if ($Day -eq 0) {
|
||||||
Write-Host -foregroundColor green "TODAY 🌡°C ☂️mm 💧 💨km/h ☀️UV ☁️ 👁km at $Area ($Region, $Country)"
|
Write-Host -foregroundColor green "TODAY 🌡°C ☂️mm 💧 💨km/h ☀️UV ☁️ 👁km at $Area ($Region, $Country)"
|
||||||
} elseif ($Day -eq 1) {
|
} elseif ($Day -eq 1) {
|
||||||
Write-Host -foregroundColor green "TOMORROW"
|
$Date = (Get-Date).AddDays(1)
|
||||||
|
[string]$Weekday = $Date.DayOfWeek
|
||||||
|
Write-Host -foregroundColor green "$($Weekday.toUpper())"
|
||||||
} else {
|
} else {
|
||||||
Write-Host -foregroundColor green "Day after tomorrow"
|
$Date = (Get-Date).AddDays(2)
|
||||||
|
[string]$Weekday = $Date.DayOfWeek
|
||||||
|
Write-Host -foregroundColor green "$($Weekday.toUpper())"
|
||||||
}
|
}
|
||||||
$Day++
|
$Day++
|
||||||
}
|
}
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
This PowerShell script determines and writes the current date.
|
This PowerShell script determines and writes the current date.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./write-date
|
PS> ./write-date
|
||||||
Sunday, October 17, 2021
|
📅12/25/2022
|
||||||
.LINK
|
.LINK
|
||||||
https://github.com/fleschutz/PowerShell
|
https://github.com/fleschutz/PowerShell
|
||||||
.NOTES
|
.NOTES
|
||||||
|
Loading…
Reference in New Issue
Block a user