mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-12-15 19:21:04 +01:00
Update check-time-zone.ps1
This commit is contained in:
parent
91566b318b
commit
67a8cc6a28
@ -17,7 +17,7 @@ try {
|
|||||||
$Time = $((Get-Date).ToShortTimeString())
|
$Time = $((Get-Date).ToShortTimeString())
|
||||||
$TZ = (Get-Timezone)
|
$TZ = (Get-Timezone)
|
||||||
if ($TZ.SupportsDaylightSavingTime) { $DST=", DST+1h" } else { $DST="" }
|
if ($TZ.SupportsDaylightSavingTime) { $DST=", DST+1h" } else { $DST="" }
|
||||||
Write-Host "✅ $Time $($TZ.Id) time (TZ+$($TZ.BaseUtcOffset)$($DST))"
|
Write-Host "✅ $Time @ $($TZ.Id) (TZ+$($TZ.BaseUtcOffset)$($DST))"
|
||||||
exit 0 # success
|
exit 0 # success
|
||||||
} catch {
|
} catch {
|
||||||
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||||
|
Loading…
Reference in New Issue
Block a user