Skip to content

Commit 9d88851

Browse files
committed
Update script: propagate custom DLL name
LibGit2Sharp must know the custom DLL name to be able to load it.
1 parent d9efc58 commit 9d88851

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

UpdateLibgit2ToSha.ps1

+4-2
Original file line numberDiff line numberDiff line change
@@ -82,19 +82,21 @@ Push-Location $libgit2Directory
8282

8383
Pop-Location
8484

85-
sc -Encoding ASCII (Join-Path $projectDirectory "nuget.package\libgit2\libgit2_hash.txt") $sha
86-
8785
if (![string]::IsNullOrEmpty($libgit2Name)) {
8886
$binaryFilename = $libgit2Name
8987
} else {
9088
$binaryFilename = "git2-" + $sha.Substring(0,7)
9189
}
9290

91+
sc -Encoding ASCII (Join-Path $projectDirectory "nuget.package\libgit2\libgit2_hash.txt") $sha
92+
sc -Encoding ASCII (Join-Path $projectDirectory "nuget.package\libgit2\libgit2_filename.txt") $binaryFilename
93+
9394
$buildProperties = @"
9495
<?xml version="1.0" encoding="utf-8"?>
9596
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
9697
<ItemGroup>
9798
<EmbeddedResource Include="`$(MSBuildThisFileDirectory)\..\libgit2\libgit2_hash.txt" />
99+
<EmbeddedResource Include="`$(MSBuildThisFileDirectory)\..\libgit2\libgit2_filename.txt" />
98100
</ItemGroup>
99101
<ItemGroup>
100102
<None Condition="Exists('`$(MSBuildThisFileDirectory)\..\libgit2\windows\amd64\$binaryFilename.dll')" Include="`$(MSBuildThisFileDirectory)\..\libgit2\windows\amd64\$binaryFilename.dll">

0 commit comments

Comments
 (0)