From 405f1ac07d78468c3e1a0ef1c0dc8956635c8677 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Wed, 22 Apr 2020 07:01:05 +0300 Subject: FSE work + fixed issue with personal access token on MS and PPC. --- Software/Visual_Studio/Tango.Core/Helpers/AssemblyHelper.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'Software/Visual_Studio/Tango.Core') diff --git a/Software/Visual_Studio/Tango.Core/Helpers/AssemblyHelper.cs b/Software/Visual_Studio/Tango.Core/Helpers/AssemblyHelper.cs index 11ef751e2..59d36533e 100644 --- a/Software/Visual_Studio/Tango.Core/Helpers/AssemblyHelper.cs +++ b/Software/Visual_Studio/Tango.Core/Helpers/AssemblyHelper.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.IO; using System.Linq; using System.Reflection; +using System.Runtime.Versioning; using System.Text; using System.Threading.Tasks; @@ -52,5 +53,13 @@ namespace Tango.Core.Helpers { return assembly.GetName().Version; } + + public static Version GetTargetFrameworkVersion(Assembly assembly) + { + object[] list = Assembly.GetExecutingAssembly().GetCustomAttributes(true); + var attribute = list.OfType().First(); + + return Version.Parse(attribute.FrameworkName.Replace(".NETFramework,Version=v", "")); + } } } -- cgit v1.3.1