feature<About>: show .NET framework version used by this application

This commit is contained in:
leo 2021-01-04 13:08:00 +08:00
parent 866f137c02
commit 065aeb67ca

View file

@ -1,3 +1,4 @@
using System;
using System.Diagnostics;
using System.Reflection;
using System.Windows;
@ -17,7 +18,10 @@ namespace SourceGit.UI {
InitializeComponent();
var asm = Assembly.GetExecutingAssembly().GetName();
version.Content = $"VERSION : v{asm.Version.Major}.{asm.Version.Minor}";
var framework = AppDomain.CurrentDomain.SetupInformation.TargetFrameworkName;
var dotnetVer = framework.Substring(framework.IndexOf("=") + 1);
version.Content = $"VERSION : v{asm.Version.Major}.{asm.Version.Minor} .NET : {dotnetVer}";
}
/// <summary>