[Windows] zstd: Invoke Move-Item with retry (#4633)
This commit is contained in:
@@ -15,7 +15,9 @@ $filesInArchive = 7z l $zstdArchivePath | Out-String
|
|||||||
|
|
||||||
if ($filesInArchive.Contains($zstdParentName)) {
|
if ($filesInArchive.Contains($zstdParentName)) {
|
||||||
Extract-7Zip -Path $zstdArchivePath -DestinationPath $toolPath
|
Extract-7Zip -Path $zstdArchivePath -DestinationPath $toolPath
|
||||||
Move-Item -Path "${zstdPath}*" -Destination $zstdPath
|
Invoke-SBWithRetry -Command {
|
||||||
|
Move-Item -Path "${zstdPath}*" -Destination $zstdPath -ErrorAction Stop
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
Extract-7Zip -Path $zstdArchivePath -DestinationPath $zstdPath
|
Extract-7Zip -Path $zstdArchivePath -DestinationPath $zstdPath
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user