Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/Core/Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
<PackageReference Include="Gameloop.Vdf" Version="0.6.2" />
<PackageReference Include="Gameloop.Vdf.JsonConverter" Version="0.2.1" />
<PackageReference Include="PCarsTools" Version="1.1.2.5" />
<!-- FIXME enter the correct version once PR merges and released (0.1.6?) -->
<PackageReference Include="OpenSimTools.LibArchive.Net" Version="0.1.6-beta0001" />
<PackageReference Include="LibArchive.Net" Version="0.3.0" />
<PackageReference Include="Octokit" Version="14.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="9.0.9" />
<PackageReference Include="Microsoft.Extensions.Configuration.CommandLine" Version="9.0.9" />
Expand Down
7 changes: 5 additions & 2 deletions tests/Core.Tests/API/ModManagerIntegrationTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
using Core.Tests.Base;
using Core.Utils;
using FluentAssertions;
using LibArchive.Net;

namespace Core.Tests.API;

Expand Down Expand Up @@ -747,9 +748,11 @@ private Package CreateModPackage(string packagePrefix, int fsHash, IEnumerable<s
}

callback(modContentsDir);

var archivePath = $@"{modsDir.FullName}\{modName}.zip";
// TODO LibArchive.Net does not support compression yet
ZipFile.CreateFromDirectory(modContentsDir, archivePath);
using var writer = new LibArchiveWriter(archivePath, ArchiveFormat.Zip);
writer.AddDirectory(modContentsDir, recursive: true);

return new Package($"{packagePrefix}{fsHash}", archivePath, true, fsHash);
}

Expand Down
Loading