Skip to content

Commit 9521fd3

Browse files
authored
Correct direct builds e.g. msbuild (#32552)
- correct `$(RepoRoot)` fallback in Directory.Build.props - need trailing slash almost everywhere - pass `$(RepoRoot)` and `$(Configuration)` properties into helix.proj - properties aren't always global and were missing when invoked from RunHelix.ps1
1 parent 9445d00 commit 9521fd3

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Directory.Build.props

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
<Import Project="eng\Common.props" />
33

44
<PropertyGroup>
5-
<RepoRoot>$(MSBuildThisFileDirectory)</RepoRoot>
5+
<!-- $(RepoRoot) is normally set globally and Arcade overrides it to ensure a trailing slash. -->
6+
<RepoRoot Condition=" '$(RepoRoot)' == '' ">$([MSBuild]::EnsureTrailingSlash('$(MSBuildThisFileDirectory)'))</RepoRoot>
7+
68
<RepositoryUrl>https://github.com/dotnet/aspnetcore</RepositoryUrl>
79
<RepositoryType>git</RepositoryType>
810
</PropertyGroup>

eng/targets/Helix.targets

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,9 @@
7373
-->
7474
<Target Name="Helix">
7575
<MSBuild Projects="$(MSBuildThisFileDirectory)..\helix\helix.proj"
76-
Properties="ProjectToBuild=$(MSBuildProjectFullPath)" />
76+
Properties="Configuration=$(Configuration);
77+
ProjectToBuild=$(MSBuildProjectFullPath);
78+
RepoRoot=$(RepoRoot)" />
7779
</Target>
7880

7981
<!-- Build the actual helix work items to send to helix queues -->

0 commit comments

Comments
 (0)