mirror of
https://github.com/ChrisTitusTech/winutil
synced 2026-04-05 14:18:31 +00:00
Fix mount disk error (#4204)
* wait for mounting to assign disk letter * update * Gabi fixing my slop with a comment
This commit is contained in:
@@ -49,8 +49,13 @@ function Invoke-WinUtilISOMountAndVerify {
|
||||
Set-WinUtilProgressBar -Label "Mounting ISO..." -Percent 10
|
||||
|
||||
try {
|
||||
$diskImage = Mount-DiskImage -ImagePath $isoPath -PassThru -ErrorAction Stop
|
||||
$driveLetter = ($diskImage | Get-Volume).DriveLetter + ":"
|
||||
Mount-DiskImage -ImagePath $isoPath -ErrorAction Stop | Out-Null
|
||||
|
||||
do {
|
||||
Start-Sleep -Milliseconds 500
|
||||
} until ((Get-DiskImage -ImagePath $isoPath | Get-Volume).DriveLetter)
|
||||
|
||||
$driveLetter = (Get-DiskImage -ImagePath $isoPath | Get-Volume).DriveLetter + ":"
|
||||
Write-Win11ISOLog "Mounted at drive $driveLetter"
|
||||
|
||||
Set-WinUtilProgressBar -Label "Verifying ISO contents..." -Percent 30
|
||||
|
||||
Reference in New Issue
Block a user