Hotfix: support WJ CDN files in the gallery

This commit is contained in:
Timothy Baldridge 2020-05-10 15:35:15 -06:00
parent 0d642fc01f
commit e35ea51480
7 changed files with 29 additions and 11 deletions

View File

@ -1,5 +1,9 @@
### Changelog
#### Version - 2.0.4.2 - 5/10/2020
* Hotfix: allow the WJ CDN to be used for gallery modlists
* Fix a bug with the CDN downloader and modlist compilation
#### Version - 2.0.4.1 - 5/10/2020
* Hotfix: don't throw a compilation exceptions when metas can't be inferred

View File

@ -6,8 +6,8 @@
<AssemblyName>wabbajack-cli</AssemblyName>
<Company>Wabbajack</Company>
<Platforms>x64</Platforms>
<AssemblyVersion>2.0.4.1</AssemblyVersion>
<FileVersion>2.0.4.1</FileVersion>
<AssemblyVersion>2.0.4.2</AssemblyVersion>
<FileVersion>2.0.4.2</FileVersion>
<Copyright>Copyright © 2019-2020</Copyright>
<Description>An automated ModList installer</Description>
<PublishReadyToRun>true</PublishReadyToRun>

View File

@ -4,8 +4,8 @@
<OutputType>WinExe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<UseWPF>true</UseWPF>
<AssemblyVersion>2.0.4.1</AssemblyVersion>
<FileVersion>2.0.4.1</FileVersion>
<AssemblyVersion>2.0.4.2</AssemblyVersion>
<FileVersion>2.0.4.2</FileVersion>
<Copyright>Copyright © 2019-2020</Copyright>
<Description>Wabbajack Application Launcher</Description>
<PublishReadyToRun>true</PublishReadyToRun>

View File

@ -12,7 +12,7 @@ using Wabbajack.Lib.Validation;
namespace Wabbajack.Lib.Downloaders
{
public class WabbajackCDNDownloader : IDownloader
public class WabbajackCDNDownloader : IDownloader, IUrlDownloader
{
public async Task<AbstractDownloadState?> GetDownloaderState(dynamic archiveINI, bool quickMode = false)
{
@ -24,7 +24,12 @@ namespace Wabbajack.Lib.Downloaders
{
}
public AbstractDownloadState? GetDownloaderState(string url)
{
return StateFromUrl(new Uri(url));
}
public static AbstractDownloadState? StateFromUrl(Uri url)
{
if (url.Host == "wabbajacktest.b-cdn.net" || url.Host == "wabbajack.b-cdn.net")

View File

@ -3,8 +3,8 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<AssemblyVersion>2.0.4.1</AssemblyVersion>
<FileVersion>2.0.4.1</FileVersion>
<AssemblyVersion>2.0.4.2</AssemblyVersion>
<FileVersion>2.0.4.2</FileVersion>
<Copyright>Copyright © 2019-2020</Copyright>
<Description>Wabbajack Server</Description>
<RuntimeIdentifier>win-x64</RuntimeIdentifier>

View File

@ -216,8 +216,17 @@ namespace Wabbajack.Test
return InstallFolder.Combine((string)Consts.MO2ModFolderName, mod, file);
}
public void VerifyAllFiles()
public void VerifyAllFiles(bool gameFileShouldNotExistInGameFolder = true)
{
if (gameFileShouldNotExistInGameFolder)
{
foreach (var file in Game.MetaData().RequiredFiles!)
{
Assert.False(InstallFolder.Combine(Consts.GameFolderFilesDir, (RelativePath)file).Exists);
}
}
var skipFiles = new []{"portable.txt"}.Select(e => (RelativePath)e).ToHashSet();
foreach (var destFile in InstallFolder.EnumerateFiles())
{

View File

@ -6,8 +6,8 @@
<UseWPF>true</UseWPF>
<Platforms>x64</Platforms>
<RuntimeIdentifier>win10-x64</RuntimeIdentifier>
<AssemblyVersion>2.0.4.1</AssemblyVersion>
<FileVersion>2.0.4.1</FileVersion>
<AssemblyVersion>2.0.4.2</AssemblyVersion>
<FileVersion>2.0.4.2</FileVersion>
<Copyright>Copyright © 2019-2020</Copyright>
<Description>An automated ModList installer</Description>
<PublishReadyToRun>true</PublishReadyToRun>