Include Wabbajack fileversion in output

This commit is contained in:
erri120
2019-10-23 18:33:53 +02:00
parent 50e9c1a07f
commit 112bf5687f
3 changed files with 7 additions and 2 deletions

View File

@ -34,6 +34,7 @@ namespace Wabbajack.Lib
public string MO2Profile; public string MO2Profile;
public string ModListName, ModListAuthor, ModListDescription, ModListWebsite, ModListImage, ModListReadme; public string ModListName, ModListAuthor, ModListDescription, ModListWebsite, ModListImage, ModListReadme;
public FileVersionInfo WabbajackVersionInfo;
public Compiler(string mo2_folder) public Compiler(string mo2_folder)
{ {
@ -275,7 +276,7 @@ namespace Wabbajack.Lib
ModList = new ModList ModList = new ModList
{ {
GameType = GameRegistry.Games.Values.First(f => f.MO2Name == MO2Ini.General.gameName).Game, GameType = GameRegistry.Games.Values.First(f => f.MO2Name == MO2Ini.General.gameName).Game,
WabbajackVersion = FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location), WabbajackVersion = WabbajackVersionInfo,
Archives = SelectedArchives, Archives = SelectedArchives,
Directives = InstallDirectives, Directives = InstallDirectives,
Name = ModListName ?? MO2Profile, Name = ModListName ?? MO2Profile,

View File

@ -47,6 +47,7 @@ namespace Wabbajack.Lib
public void Build(Compiler c, ModList lst) public void Build(Compiler c, ModList lst)
{ {
Text($"### {lst.Name} by {lst.Author} - Installation Summary"); Text($"### {lst.Name} by {lst.Author} - Installation Summary");
Text($"Build with Wabbajack Version {lst.WabbajackVersion.FileVersion}");
Text(lst.Description); Text(lst.Description);
Text($"#### Website:"); Text($"#### Website:");
NoWrapText($"[{lst.Website}]({lst.Website})"); NoWrapText($"[{lst.Website}]({lst.Website})");

View File

@ -34,6 +34,8 @@ namespace Wabbajack
{ {
public SlideShow Slideshow { get; } public SlideShow Slideshow { get; }
public readonly FileVersionInfo WabbajackVersionInfo = FileVersionInfo.GetVersionInfo(Assembly.GetEntryAssembly().Location);
private string _mo2Folder; private string _mo2Folder;
public readonly BitmapImage _noneImage = UIUtils.BitmapImageFromResource("Wabbajack.UI.none.jpg"); public readonly BitmapImage _noneImage = UIUtils.BitmapImageFromResource("Wabbajack.UI.none.jpg");
@ -350,7 +352,8 @@ namespace Wabbajack
ModListDescription = ChangedProperties ? this.Slideshow.Summary : null, ModListDescription = ChangedProperties ? this.Slideshow.Summary : null,
ModListImage = ChangedProperties ? newImagePath : null, ModListImage = ChangedProperties ? newImagePath : null,
ModListWebsite = ChangedProperties ? this.Slideshow.NexusSiteURL : null, ModListWebsite = ChangedProperties ? this.Slideshow.NexusSiteURL : null,
ModListReadme = ChangedProperties ? readmePath : null ModListReadme = ChangedProperties ? readmePath : null,
WabbajackVersionInfo = WabbajackVersionInfo
}; };
var th = new Thread(() => var th = new Thread(() =>
{ {