Install VC Redist.ps1: detect if Arm64 redist is needed

Install VC Redist.ps1: use $env instead of System.Runtime

this script now works on my VMware Fusion install on M4 (should work on arm windows sandbox now...?)
pull/2/head
exurd 2025-08-09 18:30:46 +01:00
parent df3ec01788
commit 1eb79209ae
No known key found for this signature in database
GPG Key ID: 8111E64C897D0044
1 changed files with 3 additions and 2 deletions

View File

@ -2,9 +2,10 @@
$urls = @(
"https://aka.ms/vs/17/release/vc_redist.x86.exe",
"https://aka.ms/vs/17/release/vc_redist.x64.exe"
# "https://aka.ms/vs/17/release/vc_redist.arm64.exe" # Uncomment if using Arm64 device
)
if ($env:PROCESSOR_ARCHITECTURE -eq 'ARM64') {
$urls += "https://aka.ms/vs/17/release/vc_redist.arm64.exe"
}
# Directory to save the downloads
$downloadPath = "$env:TEMP"