mirror of
https://github.com/Arvanaghi/CheckPlease
synced 2026-06-08 10:25:16 +00:00
15 lines
573 B
PowerShell
15 lines
573 B
PowerShell
#
|
|
# Checks if time zone is Coordinated Universal Time (UTC), PowerShell
|
|
# Module written by Brandon Arvanaghi
|
|
# Website: arvanaghi.com
|
|
# Twitter: @arvanaghi
|
|
#
|
|
|
|
$standardTimezone = [System.TimeZone]::CurrentTimeZone.StandardName
|
|
$daylightTimezone = [System.TimeZone]::CurrentTimeZone.DaylightName
|
|
|
|
if ($standardTimezone -eq "Coordinated Universal Time" -or $daylightTimezone -eq "Coordinated Universal Time") {
|
|
Write-Output "The time zone is Coordinated Universal Time (UTC), do not proceed."
|
|
} else {
|
|
Write-Output "The time zone is $standardTimezone. Proceed!"
|
|
} |