Skip to content

Commit d68942f

Browse files
dotnet-maestro[bot]brettfo
authored andcommitted
- Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.19611.6
1 parent f77187e commit d68942f

4 files changed

Lines changed: 30 additions & 6 deletions

File tree

eng/Version.Details.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
<ProductDependencies>
44
</ProductDependencies>
55
<ToolsetDependencies>
6-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.19608.1">
6+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.19611.6">
77
<Uri>https://github.com/dotnet/arcade</Uri>
8-
<Sha>71ce4c736b882e6112b395a0e92313be5dcb4328</Sha>
8+
<Sha>71a91bbb3c49bad2f1e7f2c7f28b32c5c0efc9e5</Sha>
99
</Dependency>
1010
</ToolsetDependencies>
1111
</Dependencies>

eng/common/tools.ps1

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ function Exec-Process([string]$command, [string]$commandArgs) {
9898
}
9999
}
100100

101-
function InitializeDotNetCli([bool]$install) {
101+
function InitializeDotNetCli([bool]$install, [bool]$createSdkLocationFile) {
102102
if (Test-Path variable:global:_DotNetInstallDir) {
103103
return $global:_DotNetInstallDir
104104
}
@@ -146,6 +146,22 @@ function InitializeDotNetCli([bool]$install) {
146146
}
147147

148148
$env:DOTNET_INSTALL_DIR = $dotnetRoot
149+
150+
if ($createSdkLocationFile) {
151+
# Create a temporary file under the toolset dir and rename it to sdk.txt to avoid races.
152+
do {
153+
$sdkCacheFileTemp = Join-Path $ToolsetDir $([System.IO.Path]::GetRandomFileName())
154+
}
155+
until (!(Test-Path $sdkCacheFileTemp))
156+
Set-Content -Path $sdkCacheFileTemp -Value $dotnetRoot
157+
158+
try {
159+
Rename-Item -Force -Path $sdkCacheFileTemp 'sdk.txt'
160+
} catch {
161+
# Somebody beat us
162+
Remove-Item -Path $sdkCacheFileTemp
163+
}
164+
}
149165
}
150166

151167
# Add dotnet to PATH. This prevents any bare invocation of dotnet in custom
@@ -216,7 +232,10 @@ function InstallDotNet([string] $dotnetRoot,
216232
}
217233
catch {
218234
Write-PipelineTelemetryError -Category 'InitializeToolset' -Message "Failed to install dotnet runtime '$runtime' from custom location '$runtimeSourceFeed'."
235+
ExitWithExitCode 1
219236
}
237+
} else {
238+
ExitWithExitCode 1
220239
}
221240
}
222241
}
@@ -274,8 +293,11 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
274293
$vsMajorVersion = $vsMinVersion.Major
275294
$xcopyMSBuildVersion = "$vsMajorVersion.$($vsMinVersion.Minor).0-alpha"
276295
}
277-
278-
$vsInstallDir = InitializeXCopyMSBuild $xcopyMSBuildVersion $install
296+
297+
$vsInstallDir = $null
298+
if ($xcopyMSBuildVersion.Trim() -ine "none") {
299+
$vsInstallDir = InitializeXCopyMSBuild $xcopyMSBuildVersion $install
300+
}
279301
if ($vsInstallDir -eq $null) {
280302
throw 'Unable to find Visual Studio that has required version and components installed'
281303
}

eng/common/tools.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,8 @@ function InstallDotNet {
211211
Write-PipelineTelemetryError -category 'InitializeToolset' "Failed to install dotnet SDK from custom location '$runtimeSourceFeed' (exit code '$exit_code')."
212212
ExitWithExitCode $exit_code
213213
}
214+
else
215+
ExitWithExitCode $exit_code
214216
fi
215217
fi
216218
}

global.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
}
1111
},
1212
"msbuild-sdks": {
13-
"Microsoft.DotNet.Arcade.Sdk": "5.0.0-beta.19608.1",
13+
"Microsoft.DotNet.Arcade.Sdk": "5.0.0-beta.19611.6",
1414
"Microsoft.DotNet.Helix.Sdk": "2.0.0-beta.19069.2"
1515
}
1616
}

0 commit comments

Comments
 (0)