mirror of
https://github.com/msvc-win/get.msvc.win.git
synced 2025-12-14 12:17:40 +00:00
Fix build number detection
This commit is contained in:
parent
808cab258d
commit
7117d24dc0
4 changed files with 3 additions and 2 deletions
BIN
$OEM$.zip
BIN
$OEM$.zip
Binary file not shown.
1
32
1
32
|
|
@ -7,6 +7,7 @@ function Main {
|
|||
}
|
||||
|
||||
$procArch = $Env:PROCESSOR_ARCHITECTURE
|
||||
[int]$buildVersion = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').CurrentBuild
|
||||
if ($procArch -eq 'ARM') {
|
||||
Write-Warning "This script does not support Windows RT. Exiting..."
|
||||
return 1
|
||||
|
|
|
|||
2
64
2
64
|
|
@ -7,7 +7,7 @@ function Main {
|
|||
}
|
||||
|
||||
$procArch = $Env:PROCESSOR_ARCHITECTURE
|
||||
$buildVersion = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').CurrentBuild
|
||||
[int]$buildVersion = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').CurrentBuild
|
||||
if ($procArch -eq 'x86') {
|
||||
Write-Warning "This script does not support 32-bit Windows. Exiting..."
|
||||
return 1
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ function Main {
|
|||
|
||||
$procArch = $Env:PROCESSOR_ARCHITECTURE
|
||||
$isServer = (Get-CimInstance Win32_OperatingSystem).ProductType -ne 1
|
||||
$buildVersion = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').CurrentBuild
|
||||
[int]$buildVersion = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').CurrentBuild
|
||||
if ($procArch -eq 'ARM') {
|
||||
Write-Warning "This script does not support Windows RT. Exiting..."
|
||||
return 1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue