From 17afaaeda90267455a488539b1c9c0c699c57577 Mon Sep 17 00:00:00 2001 From: Timothy Baldridge Date: Tue, 30 Jun 2020 22:08:34 -0600 Subject: [PATCH 1/3] Upgrade all deps --- .../Compression.BSA.Test.csproj | 2 +- Compression.BSA/Compression.BSA.csproj | 2 +- Wabbajack.App.Test/Wabbajack.App.Test.csproj | 2 +- .../Wabbajack.Common.Test.csproj | 2 +- Wabbajack.Common/Wabbajack.Common.csproj | 10 ++++----- Wabbajack.Lib/Wabbajack.Lib.csproj | 22 +++++++++---------- .../Wabbajack.Server.Test.csproj | 6 ++--- Wabbajack.Server/Wabbajack.Server.csproj | 6 ++--- Wabbajack.Test/Wabbajack.Test.csproj | 10 ++++----- .../Wabbajack.VirtualFileSystem.Test.csproj | 2 +- .../Wabbajack.VirtualFileSystem.csproj | 4 ++-- Wabbajack/Wabbajack.csproj | 20 ++++++++--------- 12 files changed, 44 insertions(+), 44 deletions(-) diff --git a/Compression.BSA.Test/Compression.BSA.Test.csproj b/Compression.BSA.Test/Compression.BSA.Test.csproj index 1797506d..ebc8f999 100644 --- a/Compression.BSA.Test/Compression.BSA.Test.csproj +++ b/Compression.BSA.Test/Compression.BSA.Test.csproj @@ -10,7 +10,7 @@ - + diff --git a/Compression.BSA/Compression.BSA.csproj b/Compression.BSA/Compression.BSA.csproj index cf206971..800e278d 100644 --- a/Compression.BSA/Compression.BSA.csproj +++ b/Compression.BSA/Compression.BSA.csproj @@ -15,7 +15,7 @@ - + diff --git a/Wabbajack.App.Test/Wabbajack.App.Test.csproj b/Wabbajack.App.Test/Wabbajack.App.Test.csproj index c3720f5f..d151d8c8 100644 --- a/Wabbajack.App.Test/Wabbajack.App.Test.csproj +++ b/Wabbajack.App.Test/Wabbajack.App.Test.csproj @@ -10,7 +10,7 @@ - + diff --git a/Wabbajack.Common.Test/Wabbajack.Common.Test.csproj b/Wabbajack.Common.Test/Wabbajack.Common.Test.csproj index 500e12ab..6dd095bf 100644 --- a/Wabbajack.Common.Test/Wabbajack.Common.Test.csproj +++ b/Wabbajack.Common.Test/Wabbajack.Common.Test.csproj @@ -10,7 +10,7 @@ - + diff --git a/Wabbajack.Common/Wabbajack.Common.csproj b/Wabbajack.Common/Wabbajack.Common.csproj index 247751cb..812548c3 100644 --- a/Wabbajack.Common/Wabbajack.Common.csproj +++ b/Wabbajack.Common/Wabbajack.Common.csproj @@ -41,19 +41,19 @@ - + - + - + - - + + diff --git a/Wabbajack.Lib/Wabbajack.Lib.csproj b/Wabbajack.Lib/Wabbajack.Lib.csproj index 067f9f91..230e15d1 100644 --- a/Wabbajack.Lib/Wabbajack.Lib.csproj +++ b/Wabbajack.Lib/Wabbajack.Lib.csproj @@ -8,25 +8,25 @@ - 81.3.100 + 83.3.120-pre - 81.3.100 + 83.3.120-pre 3.1.0 - 6.1.2 + 6.2.0 2.2.2.1 - 3.1.1 + 3.1.3 - 1.11.23 + 1.11.24 1.8.1 @@ -38,25 +38,25 @@ 2.1.0 - 11.4.1 + 11.4.17 - 11.4.1 + 11.4.17 0.25.1 - 5.0.0-preview.4.20251.6 + 5.0.0-preview.6.20305.6 - 5.0.0-preview.4.20251.6 + 5.0.0-preview.6.20305.6 4.3.4 - 5.0.0-preview.4.20251.6 + 5.0.0-preview.6.20305.6 1.0.1 @@ -68,7 +68,7 @@ 1.0.0 - 5.0.5 + 5.1.1 diff --git a/Wabbajack.Server.Test/Wabbajack.Server.Test.csproj b/Wabbajack.Server.Test/Wabbajack.Server.Test.csproj index caffc948..c3dbdd52 100644 --- a/Wabbajack.Server.Test/Wabbajack.Server.Test.csproj +++ b/Wabbajack.Server.Test/Wabbajack.Server.Test.csproj @@ -9,9 +9,9 @@ - - - + + + diff --git a/Wabbajack.Server/Wabbajack.Server.csproj b/Wabbajack.Server/Wabbajack.Server.csproj index ce0dacdf..74154e80 100644 --- a/Wabbajack.Server/Wabbajack.Server.csproj +++ b/Wabbajack.Server/Wabbajack.Server.csproj @@ -16,12 +16,12 @@ - + - + - + diff --git a/Wabbajack.Test/Wabbajack.Test.csproj b/Wabbajack.Test/Wabbajack.Test.csproj index 402fb944..4dd9124b 100644 --- a/Wabbajack.Test/Wabbajack.Test.csproj +++ b/Wabbajack.Test/Wabbajack.Test.csproj @@ -25,13 +25,13 @@ - - + + - - - + + + diff --git a/Wabbajack.VirtualFileSystem.Test/Wabbajack.VirtualFileSystem.Test.csproj b/Wabbajack.VirtualFileSystem.Test/Wabbajack.VirtualFileSystem.Test.csproj index f7eccf45..7b4f317b 100644 --- a/Wabbajack.VirtualFileSystem.Test/Wabbajack.VirtualFileSystem.Test.csproj +++ b/Wabbajack.VirtualFileSystem.Test/Wabbajack.VirtualFileSystem.Test.csproj @@ -10,7 +10,7 @@ - + diff --git a/Wabbajack.VirtualFileSystem/Wabbajack.VirtualFileSystem.csproj b/Wabbajack.VirtualFileSystem/Wabbajack.VirtualFileSystem.csproj index 8fe0e7fc..1a13f2af 100644 --- a/Wabbajack.VirtualFileSystem/Wabbajack.VirtualFileSystem.csproj +++ b/Wabbajack.VirtualFileSystem/Wabbajack.VirtualFileSystem.csproj @@ -15,8 +15,8 @@ - - + + diff --git a/Wabbajack/Wabbajack.csproj b/Wabbajack/Wabbajack.csproj index bde3bcf8..86d70664 100644 --- a/Wabbajack/Wabbajack.csproj +++ b/Wabbajack/Wabbajack.csproj @@ -55,10 +55,10 @@ - - - - + + + + all runtime; build; native; contentfiles; analyzers; buildtransitive @@ -67,13 +67,13 @@ all runtime; build; native; contentfiles; analyzers; buildtransitive - + - - - - - + + + + + From 9cf2ef97054b47d0dfb2558ca0067cfb771cd291 Mon Sep 17 00:00:00 2001 From: Timothy Baldridge Date: Tue, 30 Jun 2020 22:23:02 -0600 Subject: [PATCH 2/3] Fix tests --- Wabbajack.Test/EndToEndTests.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Wabbajack.Test/EndToEndTests.cs b/Wabbajack.Test/EndToEndTests.cs index 198da817..c491dc0f 100644 --- a/Wabbajack.Test/EndToEndTests.cs +++ b/Wabbajack.Test/EndToEndTests.cs @@ -61,7 +61,7 @@ namespace Wabbajack.Test DownloadAndInstall(Game.SkyrimSpecialEdition, 12604, "SkyUI"), DownloadAndInstall(Game.Fallout4, 11925, "Anti-Tank Rifle"), DownloadAndInstall(Game.SkyrimSpecialEdition, 4783, "Frost Armor UNP"), - DownloadAndInstall(Game.SkyrimSpecialEdition, 32359, "Frost Armor HDT")); + DownloadAndInstall(Game.SkyrimSpecialEdition, 31948, "Frost Armor HDT")); // We're going to fully patch this mod from another source. await modfiles[3].Download.DeleteAsync(); From f1e5fa9f0f442891f7718a8c78cf01ec078cda78 Mon Sep 17 00:00:00 2001 From: Timothy Baldridge Date: Wed, 1 Jul 2020 06:07:02 -0600 Subject: [PATCH 3/3] Fix timeouts caused by having too many patches --- Wabbajack.Lib/CompilationSteps/IncludePatches.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Wabbajack.Lib/CompilationSteps/IncludePatches.cs b/Wabbajack.Lib/CompilationSteps/IncludePatches.cs index 74e8476d..48ec4446 100644 --- a/Wabbajack.Lib/CompilationSteps/IncludePatches.cs +++ b/Wabbajack.Lib/CompilationSteps/IncludePatches.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Alphaleonis.Win32.Filesystem; +using F23.StringSimilarity; using Newtonsoft.Json; using Wabbajack.Common; using Wabbajack.VirtualFileSystem; @@ -75,8 +76,11 @@ namespace Wabbajack.Lib.CompilationSteps var relName = (RelativePath)Path.GetFileName(matchAllName); if (_indexedByName.TryGetValue(relName, out var arch)) { - // Just match some file in the archive based on the smallest delta difference - found = arch.SelectMany(a => a.ThisAndAllChildren).ToArray(); + var dist = new Levenshtein(); + found = arch.SelectMany(a => a.ThisAndAllChildren) + .OrderBy(a => dist.Distance(a.FullPath.FileName.ToString(), source.File.FullPath.FileName.ToString())) + .Take(3) + .ToArray(); } }