From ed145b37a6b19cac5cbd9eb5e74499471d957dcd Mon Sep 17 00:00:00 2001 From: Karthik Rajasekaran Date: Fri, 10 Mar 2017 13:32:56 -0800 Subject: [PATCH 1/2] Allow bootstrap directory to be configured --- run-build.ps1 | 4 ++++ run-build.sh | 3 +++ 2 files changed, 7 insertions(+) diff --git a/run-build.ps1 b/run-build.ps1 index 67ab3cd06f12..3f2383325397 100644 --- a/run-build.ps1 +++ b/run-build.ps1 @@ -71,6 +71,10 @@ $env:VSTEST_TRACE_BUILD=1 # set the base tools directory $toolsLocalPath = Join-Path $PSScriptRoot "build_tools" +if($env:BOOTSTRAP_INSTALL_DIR) +{ + $toolsLocalPath = $env:BOOTSTRAP_INSTALL_DIR +} $bootStrapperPath = Join-Path $toolsLocalPath "bootstrap.ps1" # if the boot-strapper script doesn't exist then download it if ((Test-Path $bootStrapperPath) -eq 0) diff --git a/run-build.sh b/run-build.sh index f96f9d0c006a..25a1fa0d4326 100755 --- a/run-build.sh +++ b/run-build.sh @@ -147,6 +147,9 @@ export VSTEST_TRACE_BUILD=1 DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1 toolsLocalPath="$REPOROOT/build_tools" +if [ ! -z $BOOTSTRAP_INSTALL_DIR]; then + toolsLocalPath = $BOOTSTRAP_INSTALL_DIR +fi bootStrapperPath="$toolsLocalPath/bootstrap.sh" dotnetInstallPath="$toolsLocalPath/dotnet-install.sh" if [ ! -f $bootStrapperPath ]; then From 54df3398ea04115aa5bf3e51c2b9e682bece5666 Mon Sep 17 00:00:00 2001 From: Karthik Rajasekaran Date: Wed, 15 Mar 2017 17:04:50 -0700 Subject: [PATCH 2/2] Allow nuget packages to be configured --- run-build.ps1 | 4 +++- run-build.sh | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/run-build.ps1 b/run-build.ps1 index 3f2383325397..ea77e898340f 100644 --- a/run-build.ps1 +++ b/run-build.ps1 @@ -29,7 +29,9 @@ if($Help) $env:CONFIGURATION = $Configuration; $RepoRoot = "$PSScriptRoot" -$env:NUGET_PACKAGES = "$RepoRoot\.nuget\packages" +if(!$env:NUGET_PACKAGES){ + $env:NUGET_PACKAGES = "$RepoRoot\.nuget\packages" +} if($NoPackage) { diff --git a/run-build.sh b/run-build.sh index 25a1fa0d4326..9c5c2beb4b1e 100755 --- a/run-build.sh +++ b/run-build.sh @@ -59,7 +59,7 @@ LINUX_PORTABLE_INSTALL_ARGS= CUSTOM_BUILD_ARGS= # Set nuget package cache under the repo -export NUGET_PACKAGES="$REPOROOT/.nuget/packages" +[ -z $NUGET_PACKAGES ] && export NUGET_PACKAGES="$REPOROOT/.nuget/packages" args=( "$@" )