Add fallback for determining LibGit2SharpPath

* Relying on $(DevEnvDir) won't work when invoking msbuild directly in
  e.g. a build process, so instead we look relative to $(VSInstallDir).
This commit is contained in:
baldurk
2017-12-15 10:26:17 +00:00
parent 92aaf0d547
commit a68e55e814
+1
View File
@@ -5,6 +5,7 @@
<!-- fetch the path of the assembly, and unescape it so MSBuild doesn't choke on brackets in "Program Files (x86)" -->
<PropertyGroup>
<LibGit2SharpPath>$([MSBuild]::Unescape("$(DevEnvDir)\CommonExtensions\Microsoft\TeamFoundation\Team Explorer\LibGit2Sharp.dll"))</LibGit2SharpPath>
<LibGit2SharpPath Condition="!exists('$(LibGit2SharpPath)')">$([MSBuild]::Unescape("$(VSInstallDir)\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer\LibGit2Sharp.dll"))</LibGit2SharpPath>
</PropertyGroup>
<!-- Declare the task with some inline code -->