Fix RHEL issue

This commit is contained in:
Unknown 2017-03-07 13:22:13 -08:00 committed by Peter Puszkiewicz
parent b80ce431ca
commit bd97d02937
2 changed files with 16 additions and 0 deletions

View file

@ -10,9 +10,18 @@
<Output TaskParameter="ConsoleOutput" PropertyName="GitInfoCommitHash" />
</Exec>
<ItemGroup>
<GitInfoCommitCountLines Include="$(GitInfoCommitCount)" />
<GitInfoCommitHashLines Include="$(GitInfoCommitHash)" />
</ItemGroup>
<PropertyGroup>
<!-- Batching in GitInfoCommitCount and GitInfoCommitHash here ensures that the property contains only the last line of the output -->
<GitInfoCommitCount>%(GitInfoCommitCountLines.Identity)</GitInfoCommitCount>
<GitInfoCommitCount>$(GitInfoCommitCount.PadLeft(6,'0'))</GitInfoCommitCount>
<GitInfoCommitHash>%(GitInfoCommitHashLines.Identity)</GitInfoCommitHash>
<ShouldOverWriteThePropsFile
Condition=" 'ForceStringComparison$(CommitCount)' != 'ForceStringComparison$(GitInfoCommitCount)' Or
'$(CommitHash)' != '$(GitInfoCommitHash)' ">true</ShouldOverWriteThePropsFile>

View file

@ -0,0 +1,7 @@
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\dir.props" />
<PropertyGroup>
<DisableImplicitFrameworkReferences>false</DisableImplicitFrameworkReferences>
</PropertyGroup>
</Project>