public async Task <GetResponse <ModList> > Compile() { string outputFile; if (string.IsNullOrWhiteSpace(Parent.OutputLocation.TargetPath)) { outputFile = MOProfile + Consts.ModListExtension; } else { outputFile = Path.Combine(Parent.OutputLocation.TargetPath, MOProfile + Consts.ModListExtension); } try { using (ActiveCompilation = new MO2Compiler( mo2Folder: Mo2Folder, mo2Profile: MOProfile, outputFile: outputFile) { ModListName = ModlistSettings.ModListName, ModListAuthor = ModlistSettings.AuthorText, ModListDescription = ModlistSettings.Description, ModListImage = ModlistSettings.ImagePath.TargetPath, ModListWebsite = ModlistSettings.Website, ModListReadme = ModlistSettings.ReadmeIsWebsite ? ModlistSettings.ReadmeWebsite : ModlistSettings.ReadmeFilePath.TargetPath, ReadmeIsWebsite = ModlistSettings.ReadmeIsWebsite, MO2DownloadsFolder = DownloadLocation.TargetPath, }) { Parent.MWVM.Settings.Performance.AttachToBatchProcessor(ActiveCompilation); var success = await ActiveCompilation.Begin(); return(GetResponse <ModList> .Create(success, ActiveCompilation.ModList)); } } finally { StatusTracker = null; ActiveCompilation = null; } }
public async Task <GetResponse <ModList> > Compile() { string outputFile = $"{ModlistSettings.ModListName}{Consts.ModListExtension}"; if (!string.IsNullOrWhiteSpace(Parent.OutputLocation.TargetPath)) { outputFile = Path.Combine(Parent.OutputLocation.TargetPath, outputFile); } try { using (ActiveCompilation = new VortexCompiler( game: SelectedGame.Game, gamePath: GameLocation.TargetPath, vortexFolder: VortexCompiler.TypicalVortexFolder(), downloadsFolder: DownloadsLocation.TargetPath, stagingFolder: StagingLocation.TargetPath, outputFile: outputFile) { ModListName = ModlistSettings.ModListName, ModListAuthor = ModlistSettings.AuthorText, ModListDescription = ModlistSettings.Description, ModListImage = ModlistSettings.ImagePath.TargetPath, ModListWebsite = ModlistSettings.Website, ModListReadme = ModlistSettings.ReadmeIsWebsite ? ModlistSettings.ReadmeWebsite : ModlistSettings.ReadmeFilePath.TargetPath, ReadmeIsWebsite = ModlistSettings.ReadmeIsWebsite, }) { Parent.MWVM.Settings.Performance.AttachToBatchProcessor(ActiveCompilation); var success = await ActiveCompilation.Begin(); return(GetResponse <ModList> .Create(success, ActiveCompilation.ModList)); } } finally { StatusTracker = null; ActiveCompilation.Dispose(); ActiveCompilation = null; } }
public bool Equals(GetResponse <T> other) { return(Succeeded == other.Succeeded && Equals(Value, other.Value)); }
public bool Equals(GetResponse <T> other) { return(this.Succeeded == other.Succeeded && object.Equals(this.Value, other.Value)); }