@@ -133,31 +133,6 @@ steps:
133133 condition : and(succeeded(), contains('${{ parameters.framework }}', 'net8.'), eq('${{ parameters.vsTestPlatform }}', 'x86'))
134134
135135
136- - task : UseDotNet@2
137- displayName : ' Use .NET SDK 6.0.421'
138- inputs :
139- packageType : ' sdk'
140- version : ' 6.0.421'
141- performMultiLevelLookup : ' ${{ variables.PerformMultiLevelLookup }}'
142- condition : and(succeeded(), contains('${{ parameters.framework }}', 'net6.'))
143-
144- # Hack: .NET 8+ no longer installs the x86 bits and they must be installed separately. However, it is not
145- # trivial to get it into the path and to get it to pass the minimum SDK version check in runbuild.ps1.
146- # So, we install it afterward and set the environment variable so the above SDK can delegate to it.
147- # This code only works on Windows.
148- - pwsh : |
149- $sdkVersion = '6.0.421'
150- $architecture = '${{ parameters.vsTestPlatform }}'
151- $installScriptPath = "${env:AGENT_TEMPDIRECTORY}/dotnet-install.ps1"
152- $installScriptUrl = "https://raw.githubusercontent.com/dotnet/install-scripts/main/src/dotnet-install.ps1"
153- [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
154- Invoke-WebRequest $installScriptUrl -OutFile $installScriptPath -TimeoutSec 60
155- $installPath = "${env:ProgramFiles(x86)}/dotnet"
156- & $installScriptPath -Version $sdkVersion -Architecture $architecture -InstallDir $installPath
157- Write-Host "##vso[task.setvariable variable=DOTNET_ROOT_X86;]$installPath"
158- displayName : ' Use .NET SDK 6.0.421 (x86)'
159- condition : and(succeeded(), contains('${{ parameters.framework }}', 'net6.'), eq('${{ parameters.vsTestPlatform }}', 'x86'))
160-
161136# - template: 'show-all-files.yml' # Uncomment for debugging
162137- pwsh : |
163138 $framework = '${{ parameters.framework }}'
0 commit comments