Skip to content

Commit

Permalink
Use official KeePass for ReleaseDll
Browse files Browse the repository at this point in the history
The .dll build with ReleaseDll will fail to load in KeePass because the
NuGet KeePass is an unofficial debug build and is not strongly versioned
(lacks public key token). So we have to build against the official
signed KeePass version.
  • Loading branch information
dlech committed Dec 24, 2023
1 parent a947e8e commit bdc479a
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 5 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ jobs:
with:
submodules: true

- run: nuget restore
- name: Install prerequisites
run: |
choco install keepass
nuget restore
- name: Setup MSBuild.exe
uses: microsoft/[email protected]
Expand Down
24 changes: 20 additions & 4 deletions KeeAgent/KeeAgent.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -253,11 +253,27 @@
<ItemGroup>
<None Include="Resources\help-3.png" />
</ItemGroup>
<Choose>
<When Condition="'$(Configuration)' == 'ReleaseDll'">
<ItemGroup Condition=" '$(OS)' != 'Unix' ">
<Reference Include="KeePass">
<HintPath>$(ProgramFiles)\KeePass Password Safe 2\KeePass.exe</HintPath>
<ExcludeFromPlgx />
</Reference>
</ItemGroup>
</When>
</Choose>
<Choose>
<When Condition="'$(Configuration)' != 'ReleaseDll'">
<ItemGroup Condition=" '$(OS)' != 'Unix' ">
<PackageReference Include="KeePass">
<Version>2.53.0.21099</Version>
<ExcludeFromPlgx />
</PackageReference>
</ItemGroup>
</When>
</Choose>
<ItemGroup Condition=" '$(OS)' != 'Unix' ">
<PackageReference Include="KeePass">
<Version>2.53.0.21099</Version>
<ExcludeFromPlgx />
</PackageReference>
<PackageReference Include="ILRepack">
<Version>2.0.20</Version>
<PrivateAssets>all</PrivateAssets>
Expand Down

0 comments on commit bdc479a

Please sign in to comment.