File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -119,7 +119,7 @@ switch ((Get-WindowsImage -ImagePath $wimFilePath -Index $index).Architecture)
119
119
{
120
120
0 { $architecture = " x86" }
121
121
9 { $architecture = " amd64" }
122
- 12 {$architecture = " arm64" }
122
+ 12 { $architecture = " arm64" }
123
123
}
124
124
125
125
if (Test-Path variable:architecture) {
@@ -444,19 +444,19 @@ if ($null -ne $WinSDKPath) {
444
444
}
445
445
$localOSCDIMGPath = " $PSScriptRoot \oscdimg.exe"
446
446
447
- if ((Test-Path variable:ADKDepTools) -and (Test-Path " $ADKDepTools \oscdimg.exe" - PathType leaf )) {
447
+ if ((Test-Path variable:ADKDepTools) -and (Test-Path - Path " $ADKDepTools \oscdimg.exe" - PathType Leaf )) {
448
448
Write-Host " Will be using oscdimg.exe from system ADK."
449
449
$OSCDIMG = " $ADKDepTools \oscdimg.exe"
450
450
} else {
451
451
Write-Host " oscdimg.exe from system ADK not found. Will be using bundled oscdimg.exe."
452
452
453
453
$url = " https://msdl.microsoft.com/download/symbols/oscdimg.exe/3D44737265000/oscdimg.exe"
454
454
455
- if (-not (Test-Path - Path $localOSCDIMGPath )) {
455
+ if (-not (Test-Path - Path $localOSCDIMGPath - PathType Leaf )) {
456
456
Write-Host " Downloading oscdimg.exe..."
457
457
Invoke-WebRequest - Uri $url - OutFile $localOSCDIMGPath
458
458
459
- if (Test-Path $localOSCDIMGPath ) {
459
+ if (Test-Path - Path $localOSCDIMGPath - PathType Leaf ) {
460
460
Write-Host " oscdimg.exe downloaded successfully."
461
461
} else {
462
462
Write-Error " Failed to download oscdimg.exe."
You can’t perform that action at this time.
0 commit comments