Skip to content

Commit 902f7b7

Browse files
authored
Fix GitVersioning after recent BuildTools update (#1282)
BuildTools now writes a file named "version.txt" which is unfortunate because GitVersioning also looks for a file named that. This change sets $(ObjDir) so the BuildTools version.txt will be out of the paths taht GitVersioning searches.
1 parent 769a0e7 commit 902f7b7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

dir.props

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,9 @@
385385
<IntermediateOutputPath>$([System.IO.Path]::Combine($(BaseIntermediateOutputPath)$(MSBuildProjectName),$(Configuration)))$([System.IO.Path]::DirectorySeparatorChar)</IntermediateOutputPath>
386386
<IntermediateOutputPath Condition="'$(Platform)' != 'AnyCPU'">$([System.IO.Path]::Combine($(BaseIntermediateOutputPath)$(MSBuildProjectName),$(Platform),$(Configuration)))$([System.IO.Path]::DirectorySeparatorChar)</IntermediateOutputPath>
387387

388+
<!-- BuildTools uses this path to write some files -->
389+
<ObjDir>$(IntermediateOutputPath)</ObjDir>
390+
388391
<!-- The TestPath seems to be used by Microsoft.DotNet.BuildTools targets. It does not seem to affect the MSBuild build in any way -->
389392
<TestPath>$(TestWorkingDir)$([System.IO.Path]::Combine($(MSBuildProjectName),$(Configuration)))$([System.IO.Path]::DirectorySeparatorChar)</TestPath>
390393
<TestPath Condition="'$(Platform)' != 'AnyCPU'">$([System.IO.Path]::Combine($(TestWorkingDir)$(MSBuildProjectName),$(Platform),$(Configuration)))$([System.IO.Path]::DirectorySeparatorChar)</TestPath>

0 commit comments

Comments
 (0)