From 4a37ec2dd54740463e6d0b540eaa243aeea7184f Mon Sep 17 00:00:00 2001 From: Heikki Halmet Date: Tue, 19 Nov 2019 10:13:21 +0200 Subject: Provisioning: Use Remove function when removing items in Windows MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sometimes items are locked by some windows process so that they can't be removed. This will fail provisioning instantly. Let's give the removing process more time by retrying if it will fail on first attempt Change-Id: Ic5c16c0d920ed0625d0c6830323d0bc6ba2cd608 Reviewed-by: Tony Sarajärvi --- coin/provisioning/common/windows/python3.ps1 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'coin/provisioning/common/windows/python3.ps1') diff --git a/coin/provisioning/common/windows/python3.ps1 b/coin/provisioning/common/windows/python3.ps1 index 58cd25c5..874f2f06 100644 --- a/coin/provisioning/common/windows/python3.ps1 +++ b/coin/provisioning/common/windows/python3.ps1 @@ -60,8 +60,7 @@ Download $externalUrl $internalUrl $package Verify-Checksum $package $sha1 Write-Host "Installing $package..." Run-Executable "$package" "/q TargetDir=$install_path" -Write-Host "Remove $package..." -Remove-Item -Path $package +Remove "$package" # For cross-compilation we export some helper env variable if (($archVer -eq 32) -And (Is64BitWinHost)) { -- cgit v1.2.3