mirror of
https://github.com/wabbajack-tools/wabbajack.git
synced 2024-08-30 18:42:17 +00:00
ExtensionManager.Extension -> ModListExtension
This commit is contained in:
parent
ab4371e5d2
commit
4138e644ef
@ -10,10 +10,10 @@ namespace Wabbajack.Common
|
||||
[DllImport("Shell32.dll", CharSet = CharSet.Auto, SetLastError = true)]
|
||||
public static extern void SHChangeNotify(uint wEventId, uint uFlags, IntPtr dwItem1, IntPtr dwItem2);
|
||||
|
||||
public static string Extension = ".wabbajack";
|
||||
public static string ModListExtension = ".wabbajack";
|
||||
|
||||
private static readonly string ProgIDPath = "Software\\Classes\\Wabbajack";
|
||||
private static readonly string ExtPath = $"Software\\Classes\\{Extension}";
|
||||
private static readonly string ExtPath = $"Software\\Classes\\{ModListExtension}";
|
||||
|
||||
private static readonly Dictionary<string, string> ProgIDList = new Dictionary<string, string>
|
||||
{
|
||||
|
@ -361,7 +361,7 @@ namespace Wabbajack.Lib
|
||||
foreach (var file in Directory.EnumerateFiles(path))
|
||||
{
|
||||
if (!File.Exists(file)) continue;
|
||||
if (System.IO.Path.GetExtension(file).Equals(ExtensionManager.Extension))
|
||||
if (System.IO.Path.GetExtension(file).Equals(ExtensionManager.ModListExtension))
|
||||
{
|
||||
return ErrorResponse.Fail($"Cannot install into a folder with a Wabbajack ModList inside of it");
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ namespace Wabbajack.Lib
|
||||
if (string.IsNullOrEmpty(ModListName))
|
||||
{
|
||||
ModListName = $"Vortex ModList for {Game.ToString()}";
|
||||
ModListOutputFile = $"{ModListName}{ExtensionManager.Extension}";
|
||||
ModListOutputFile = $"{ModListName}{ExtensionManager.ModListExtension}";
|
||||
}
|
||||
|
||||
GameName = Game.MetaData().NexusName;
|
||||
|
@ -38,7 +38,7 @@ namespace Wabbajack.Test
|
||||
var compiler = new MO2Compiler(
|
||||
mo2Folder: utils.MO2Folder,
|
||||
mo2Profile: profile,
|
||||
outputFile: profile + ExtensionManager.Extension);
|
||||
outputFile: profile + ExtensionManager.ModListExtension);
|
||||
compiler.ShowReportWhenFinished = false;
|
||||
Assert.IsTrue(await compiler.Begin());
|
||||
return compiler;
|
||||
|
@ -51,7 +51,7 @@ namespace Wabbajack.Test
|
||||
vortexFolder: VortexCompiler.TypicalVortexFolder(),
|
||||
downloadsFolder: VortexCompiler.RetrieveDownloadLocation(utils.Game),
|
||||
stagingFolder: VortexCompiler.RetrieveStagingLocation(utils.Game),
|
||||
outputFile: $"test{ExtensionManager.Extension}");
|
||||
outputFile: $"test{ExtensionManager.ModListExtension}");
|
||||
}
|
||||
|
||||
protected async Task<ModList> CompileAndInstall()
|
||||
|
@ -76,7 +76,7 @@ namespace Wabbajack.Test
|
||||
var compiler = new MO2Compiler(
|
||||
mo2Folder: utils.InstallFolder,
|
||||
mo2Profile: profile,
|
||||
outputFile: profile + ExtensionManager.Extension);
|
||||
outputFile: profile + ExtensionManager.ModListExtension);
|
||||
compiler.MO2DownloadsFolder = Path.Combine(utils.DownloadsFolder);
|
||||
compiler.ShowReportWhenFinished = false;
|
||||
Assert.IsTrue(await compiler.Begin());
|
||||
@ -165,7 +165,7 @@ namespace Wabbajack.Test
|
||||
var compiler = new MO2Compiler(
|
||||
mo2Folder: utils.MO2Folder,
|
||||
mo2Profile: profile,
|
||||
outputFile: profile + ExtensionManager.Extension);
|
||||
outputFile: profile + ExtensionManager.ModListExtension);
|
||||
compiler.ShowReportWhenFinished = false;
|
||||
Assert.IsTrue(await compiler.Begin());
|
||||
return compiler;
|
||||
|
@ -47,7 +47,7 @@ namespace Wabbajack.Test
|
||||
using (var tempDir = new TempFolder())
|
||||
{
|
||||
File.Create(Path.Combine(tempDir.Dir.FullName, $"ModOrganizer.exe"));
|
||||
File.Create(Path.Combine(tempDir.Dir.FullName, $"modlist{ExtensionManager.Extension}"));
|
||||
File.Create(Path.Combine(tempDir.Dir.FullName, $"modlist{ExtensionManager.ModListExtension}"));
|
||||
Assert.IsFalse(MO2Installer.CheckValidInstallPath(tempDir.Dir.FullName, downloadFolder: null).Succeeded);
|
||||
}
|
||||
}
|
||||
|
@ -168,11 +168,11 @@ namespace Wabbajack
|
||||
string outputFile;
|
||||
if (string.IsNullOrWhiteSpace(Parent.OutputLocation.TargetPath))
|
||||
{
|
||||
outputFile = MOProfile + ExtensionManager.Extension;
|
||||
outputFile = MOProfile + ExtensionManager.ModListExtension;
|
||||
}
|
||||
else
|
||||
{
|
||||
outputFile = Path.Combine(Parent.OutputLocation.TargetPath, MOProfile + ExtensionManager.Extension);
|
||||
outputFile = Path.Combine(Parent.OutputLocation.TargetPath, MOProfile + ExtensionManager.ModListExtension);
|
||||
}
|
||||
|
||||
try
|
||||
|
@ -179,7 +179,7 @@ namespace Wabbajack
|
||||
|
||||
public async Task<bool> Compile()
|
||||
{
|
||||
string outputFile = $"{ModlistSettings.ModListName}{ExtensionManager.Extension}";
|
||||
string outputFile = $"{ModlistSettings.ModListName}{ExtensionManager.ModListExtension}";
|
||||
if (!string.IsNullOrWhiteSpace(Parent.OutputLocation.TargetPath))
|
||||
{
|
||||
outputFile = Path.Combine(Parent.OutputLocation.TargetPath, outputFile);
|
||||
|
@ -52,7 +52,7 @@ namespace Wabbajack
|
||||
{
|
||||
_parent = parent;
|
||||
Metadata = metadata;
|
||||
Location = Path.Combine(Consts.ModListDownloadFolder, Metadata.Links.MachineURL + ExtensionManager.Extension);
|
||||
Location = Path.Combine(Consts.ModListDownloadFolder, Metadata.Links.MachineURL + ExtensionManager.ModListExtension);
|
||||
IsBroken = metadata.ValidationSummary.HasFailures;
|
||||
OpenWebsiteCommand = ReactiveCommand.Create(() => Process.Start($"https://www.wabbajack.org/modlist/{Metadata.Links.MachineURL}"));
|
||||
ExecuteCommand = ReactiveCommand.CreateFromObservable<Unit, Unit>(
|
||||
|
@ -27,7 +27,7 @@ namespace Wabbajack
|
||||
if (string.IsNullOrWhiteSpace(path)
|
||||
|| !File.Exists(path))
|
||||
{
|
||||
path = UIUtils.OpenFileDialog($"*{ExtensionManager.Extension}|*{ExtensionManager.Extension}");
|
||||
path = UIUtils.OpenFileDialog($"*{ExtensionManager.ModListExtension}|*{ExtensionManager.ModListExtension}");
|
||||
}
|
||||
_mainVM.OpenInstaller(path);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user