From 61c1c216ba42cdda2ed4f4eaa5c3e75e9b19bcc2 Mon Sep 17 00:00:00 2001 From: Coen van den Munckhof Date: Thu, 5 Sep 2024 19:53:58 +0200 Subject: [PATCH] Show current version (using nbgv) in help page --- src/RepoM.App/ViewModels/HelpViewModel.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/RepoM.App/ViewModels/HelpViewModel.cs b/src/RepoM.App/ViewModels/HelpViewModel.cs index ce82d0de..612c3592 100644 --- a/src/RepoM.App/ViewModels/HelpViewModel.cs +++ b/src/RepoM.App/ViewModels/HelpViewModel.cs @@ -21,8 +21,7 @@ public HelpViewModel(ITranslationService translationService) private static string GetHeader() { - AssemblyName? appName = Assembly.GetEntryAssembly()?.GetName(); - return appName?.Name + ' ' + appName?.Version?.ToString(2).Trim(); + return ((Assembly.GetEntryAssembly()?.GetName().Name ?? ThisAssembly.AssemblyName) + " " + ThisAssembly.AssemblyInformationalVersion).Trim(); } private static string GetHelp(ITranslationService translationService)