Skip to content

Commit 063e40d

Browse files
ASP.NET Push Botunknown
authored andcommitted
⬆️ dnvm.ps1, dnvm.cmd, dnvm.sh
Source: aspnet/dnvm@69bc83e
1 parent eae4cda commit 063e40d

File tree

2 files changed

+19
-7
lines changed

2 files changed

+19
-7
lines changed

dnvm.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ function _WriteOut {
6767

6868
### Constants
6969
$ProductVersion="1.0.0"
70-
$BuildVersion="beta8-15514"
70+
$BuildVersion="beta8-15515"
7171
$Authors="Microsoft Open Technologies, Inc."
7272

7373
# If the Version hasn't been replaced...
@@ -1598,7 +1598,7 @@ function dnvm-run {
15981598
[Parameter(Mandatory=$false, Position=1, ValueFromRemainingArguments=$true)]
15991599
[object[]]$DnxArguments)
16001600

1601-
$runtimeInfo = Get-RuntimeAliasOrRuntimeInfo -Version:$VersionOrAlias
1601+
$runtimeInfo = Get-RuntimeAliasOrRuntimeInfo -Version:$VersionOrAlias -Runtime:$Runtime -Architecture:$Architecture
16021602

16031603
$runtimeBin = Get-RuntimePath $runtimeInfo.RuntimeName
16041604
if ($runtimeBin -eq $null) {
@@ -1639,7 +1639,7 @@ function dnvm-exec {
16391639
[Parameter(Mandatory=$false, Position=2, ValueFromRemainingArguments=$true)]
16401640
[object[]]$Arguments)
16411641

1642-
$runtimeInfo = Get-RuntimeAliasOrRuntimeInfo -Version:$VersionOrAlias
1642+
$runtimeInfo = Get-RuntimeAliasOrRuntimeInfo -Version:$VersionOrAlias -Runtime:$Runtime -Architecture:$Architecture
16431643
$runtimeBin = Get-RuntimePath $runtimeInfo.RuntimeName
16441644

16451645
if ($runtimeBin -eq $null) {

dnvm.sh

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Source this file from your .bash-profile or script to use
33

44
# "Constants"
5-
_DNVM_BUILDNUMBER="beta8-15514"
5+
_DNVM_BUILDNUMBER="beta8-15515"
66
_DNVM_AUTHORS="Microsoft Open Technologies, Inc."
77
_DNVM_RUNTIME_PACKAGE_NAME="dnx"
88
_DNVM_RUNTIME_FRIENDLY_NAME=".NET Execution Environment"
@@ -684,9 +684,9 @@ dnvm()
684684
local arch=
685685
local runtime=
686686

687+
local versionOrAlias=
687688
shift
688689
if [ $cmd == "use" ]; then
689-
local versionOrAlias=
690690
while [ $# -ne 0 ]
691691
do
692692
if [[ $1 == "-p" || $1 == "-persistent" ]]; then
@@ -706,8 +706,20 @@ dnvm()
706706
shift
707707
done
708708
else
709-
local versionOrAlias=$1
710-
shift
709+
while [ $# -ne 0 ]
710+
do
711+
if [[ $1 == "-a" || $1 == "-arch" ]]; then
712+
local arch=$2
713+
shift
714+
elif [[ $1 == "-r" || $1 == "-runtime" ]]; then
715+
local runtime=$2
716+
shift
717+
elif [[ -n $1 ]]; then
718+
[[ -n $versionOrAlias ]] && break
719+
local versionOrAlias=$1
720+
fi
721+
shift
722+
done
711723
fi
712724

713725
if [[ $cmd == "use" && $versionOrAlias == "none" ]]; then

0 commit comments

Comments
 (0)