From c98372f0be55d65e1927182e16bc9618d9c66ec0 Mon Sep 17 00:00:00 2001 From: Daniel Plaisted Date: Wed, 6 Nov 2019 11:19:46 -0800 Subject: [PATCH] Update dogfood scripts for new layout --- eng/dogfood.ps1 | 14 ++++++++------ eng/dogfood.sh | 12 +++++++----- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/eng/dogfood.ps1 b/eng/dogfood.ps1 index 3b43a6999458..1f21c08b104c 100644 --- a/eng/dogfood.ps1 +++ b/eng/dogfood.ps1 @@ -36,12 +36,14 @@ try { . $PSScriptroot\restore-toolset.ps1 $env:SDK_REPO_ROOT = $RepoRoot - $env:SDK_CLI_VERSION = $GlobalJson.tools.dotnet - $env:MSBuildSDKsPath = Join-Path $ArtifactsDir "bin\$configuration\Sdks" - $env:DOTNET_MSBUILD_SDK_RESOLVER_SDKS_DIR = $env:MSBuildSDKsPath - $env:NETCoreSdkBundledVersionsProps = Join-Path $env:DOTNET_INSTALL_DIR "sdk\$env:SDK_CLI_VERSION\Microsoft.NETCoreSdk.BundledVersions.props" - $env:MicrosoftNETBuildExtensionsTargets = Join-Path $env:MSBuildSDKsPath "Microsoft.NET.Build.Extensions\msbuildExtensions\Microsoft\Microsoft.NET.Build.Extensions\Microsoft.NET.Build.Extensions.targets" - $env:DOTNET_ROOT = $env:DOTNET_INSTALL_DIR + + $TestDotnetRoot = Join-Path $ArtifactsDir "bin\redist\$configuration\dotnet" + + $testDotnetVersion = (Get-Childitem -Directory "$TestDotnetRoot\sdk")[0] + $env:DOTNET_MSBUILD_SDK_RESOLVER_SDKS_DIR = Join-Path $TestDotnetRoot "sdk\$testDotnetVersion\Sdks" + $env:MicrosoftNETBuildExtensionsTargets = Join-Path $ArtifactsDir "bin\$configuration\Sdks\Microsoft.NET.Build.Extensions\msbuildExtensions\Microsoft\Microsoft.NET.Build.Extensions\Microsoft.NET.Build.Extensions.targets" + + $env:PATH = "$TestDotnetRoot;$env:Path" if ($command -eq $null -and $env:DOTNET_SDK_DOGFOOD_SHELL -ne $null) { $command = , $env:DOTNET_SDK_DOGFOOD_SHELL diff --git a/eng/dogfood.sh b/eng/dogfood.sh index b873e9d05d1a..e89086a580d4 100644 --- a/eng/dogfood.sh +++ b/eng/dogfood.sh @@ -17,8 +17,10 @@ ReadGlobalVersion "dotnet" dotnet_sdk_version=$_ReadGlobalVersion export SDK_REPO_ROOT="$repo_root" -export SDK_CLI_VERSION="$dotnet_sdk_version" -export MSBuildSDKsPath="$artifacts_dir/bin/$configuration/Sdks" -export DOTNET_MSBUILD_SDK_RESOLVER_SDKS_DIR="$MSBuildSDKsPath" -export NETCoreSdkBundledVersionsProps="$DOTNET_INSTALL_DIR/sdk/$dotnet_sdk_version/Microsoft.NETCoreSdk.BundledVersions.props" -export MicrosoftNETBuildExtensionsTargets="$MSBuildSDKsPath/Microsoft.NET.Build.Extensions/msbuildExtensions/Microsoft/Microsoft.NET.Build.Extensions/Microsoft.NET.Build.Extensions.targets" + +testDotnetRoot="$artifacts_dir/bin/redist/$configuration/dotnet" +testDotnetVersion=$(ls $testDotnetRoot/sdk) +export DOTNET_MSBUILD_SDK_RESOLVER_SDKS_DIR="$testDotnetRoot/sdk/$testDotnetVersion/Sdks" +export MicrosoftNETBuildExtensionsTargets="$artifacts_dir/bin/$configuration/Sdks/Microsoft.NET.Build.Extensions/msbuildExtensions/Microsoft/Microsoft.NET.Build.Extensions/Microsoft.NET.Build.Extensions.targets" + +export PATH=$testDotnetRoot:$PATH \ No newline at end of file