⬆️ dnvm.ps1, dnvm.cmd, dnvm.sh

Source: aspnet/dnvm@66364c7eb4
This commit is contained in:
ASP.NET Push Bot 2015-10-14 15:44:50 -07:00 committed by unknown
parent 86c75018d0
commit 39c901ee4e
2 changed files with 14 additions and 5 deletions

View File

@ -67,7 +67,7 @@ function _WriteOut {
### Constants
$ProductVersion="1.0.0"
$BuildVersion="rc1-15526"
$BuildVersion="rc1-15527"
$Authors="Microsoft Open Technologies, Inc."
# If the Version hasn't been replaced...
@ -846,6 +846,14 @@ function Is-Elevated() {
return $user.IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")
}
function Get-ScriptRoot() {
if ($PSVersionTable.PSVersion.Major -ge 3) {
return $PSScriptRoot
}
return Split-Path $script:MyInvocation.MyCommand.Path -Parent
}
### Commands
<#
@ -863,9 +871,10 @@ function dnvm-update-self {
$wc = New-Object System.Net.WebClient
Apply-Proxy $wc -Proxy:$Proxy
$dnvmFile = Join-Path $PSScriptRoot "dnvm.ps1"
$tempDnvmFile = Join-Path $PSScriptRoot "temp"
$backupFilePath = Join-Path $PSSCriptRoot "dnvm.ps1.bak"
$CurrentScriptRoot = Get-ScriptRoot
$dnvmFile = Join-Path $CurrentScriptRoot "dnvm.ps1"
$tempDnvmFile = Join-Path $CurrentScriptRoot "temp"
$backupFilePath = Join-Path $CurrentScriptRoot "dnvm.ps1.bak"
$wc.DownloadFile($DNVMUpgradeUrl, $tempDnvmFile)

View File

@ -2,7 +2,7 @@
# Source this file from your .bash-profile or script to use
# "Constants"
_DNVM_BUILDNUMBER="rc1-15526"
_DNVM_BUILDNUMBER="rc1-15527"
_DNVM_AUTHORS="Microsoft Open Technologies, Inc."
_DNVM_RUNTIME_PACKAGE_NAME="dnx"
_DNVM_RUNTIME_FRIENDLY_NAME=".NET Execution Environment"