Created
May 25, 2016 14:50
-
-
Save gbnk0/ad241d57c18c30f99fa1d75ad473b8c6 to your computer and use it in GitHub Desktop.
Detect windows version powershell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Detect windows version | |
if ([environment]::OSVersion.Version.Major -ge 6){ | |
Write-Output "Win2008 or after" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment