From 98355aa2af83ee14599d21efea2cd6b1f85dea3b Mon Sep 17 00:00:00 2001 From: "ASP.NET Push Bot" Date: Mon, 2 Nov 2015 09:59:52 -0800 Subject: [PATCH] :arrow_up: dnvm.ps1, dnvm.cmd, dnvm.sh Source: aspnet/dnvm@74cbefa79c58d74c456ed60e707633c6d483198e --- dnvm.ps1 | 24 ++++++++++++++++-------- dnvm.sh | 2 +- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/dnvm.ps1 b/dnvm.ps1 index fcd16013bb..b7281be98c 100644 --- a/dnvm.ps1 +++ b/dnvm.ps1 @@ -67,7 +67,7 @@ function _WriteOut { ### Constants $ProductVersion="1.0.0" -$BuildVersion="rc2-15538" +$BuildVersion="rc2-15539" $Authors="Microsoft Open Technologies, Inc." # If the Version hasn't been replaced... @@ -1466,13 +1466,21 @@ function dnvm-install { else { _WriteOut "Installing to $RuntimeFolder" _WriteDebug "Moving package contents to $RuntimeFolder" - try { - Move-Item $UnpackFolder $RuntimeFolder - } catch { - if(Test-Path $RuntimeFolder) { - #Attempt to cleanup the runtime folder if it is there after a fail. - Remove-Item $RuntimeFolder -Recurse -Force - throw + $retry=0 + while($retry -ne 2) { + try { + Move-Item $UnpackFolder $RuntimeFolder -Force + break + } catch { + $retry=$retry+1 + if($retry -eq 2) { + if(Test-Path $RuntimeFolder) { + #Attempt to cleanup the runtime folder if it is there after a fail. + _WriteDebug "Deleting $RuntimeFolder" + Remove-Item $RuntimeFolder -Recurse -Force + throw + } + } } } #If there is nothing left in the temp folder remove it. There could be other installs happening at the same time as this. diff --git a/dnvm.sh b/dnvm.sh index c71562ca40..c6e89fefa7 100644 --- a/dnvm.sh +++ b/dnvm.sh @@ -2,7 +2,7 @@ # Source this file from your .bash-profile or script to use # "Constants" -_DNVM_BUILDNUMBER="rc2-15538" +_DNVM_BUILDNUMBER="rc2-15539" _DNVM_AUTHORS="Microsoft Open Technologies, Inc." _DNVM_RUNTIME_PACKAGE_NAME="dnx" _DNVM_RUNTIME_FRIENDLY_NAME=".NET Execution Environment"