diff options
author | Nate McMaster <natemcmaster@users.noreply.github.com> | 2018-10-12 02:20:46 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-12 02:20:46 +0300 |
commit | b833d1df88aa187fed81908073fdeed291b8ea8d (patch) | |
tree | fc4a27aa577a0aed814ad820312442f49a9c913d | |
parent | 867a9423f7440cdeb240ef2d13e34362f332c56b (diff) |
Set DOTNET_HOME to repo dir when `--ci` is specified (#1490)
-rw-r--r-- | run.ps1 | 1 | ||||
-rwxr-xr-x | run.sh | 6 |
2 files changed, 6 insertions, 1 deletions
@@ -201,6 +201,7 @@ if (Test-Path $ConfigFile) { if (!$DotNetHome) { $DotNetHome = if ($env:DOTNET_HOME) { $env:DOTNET_HOME } ` + elseif ($CI) { Join-Path $PSScriptRoot '.dotnet' } ` elseif ($env:USERPROFILE) { Join-Path $env:USERPROFILE '.dotnet'} ` elseif ($env:HOME) {Join-Path $env:HOME '.dotnet'}` else { Join-Path $PSScriptRoot '.dotnet'} @@ -11,7 +11,6 @@ RED="\033[0;31m" YELLOW="\033[0;33m" MAGENTA="\033[0;95m" DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" -[ -z "${DOTNET_HOME:-}" ] && DOTNET_HOME="$HOME/.dotnet" verbose=false update=false reinstall=false @@ -220,6 +219,9 @@ while [[ $# -gt 0 ]]; do ;; --ci|-[Cc][Ii]) ci=true + if [[ -z "${DOTNET_HOME:-}" ]]; then + DOTNET_HOME="$DIR/.dotnet" + fi ;; --verbose|-Verbose) verbose=true @@ -265,6 +267,8 @@ if [ -f "$config_file" ]; then [ ! -z "${config_tools_source:-}" ] && tools_source="$config_tools_source" fi +[ -z "${DOTNET_HOME:-}" ] && DOTNET_HOME="$HOME/.dotnet" + if [ ! -z "$package_version_props_url" ]; then intermediate_dir="$repo_path/obj" props_file_path="$intermediate_dir/external-dependencies.props" |