diff --git a/Il2CppInspector.CLI/Program.cs b/Il2CppInspector.CLI/Program.cs index 9181b077..7cc7786f 100644 --- a/Il2CppInspector.CLI/Program.cs +++ b/Il2CppInspector.CLI/Program.cs @@ -172,17 +172,18 @@ private static int DisplayHelp(ParserResult result, IEnumerable } private static int Run(Options options) { - - // Banner - var location = Assembly.GetEntryAssembly().Location; - if (location == "") // Single file executables don't have an assembly location - location = Path.Join(AppContext.BaseDirectory, "Il2CppInspector.exe"); - - var asmInfo = FileVersionInfo.GetVersionInfo(location); - Console.WriteLine(asmInfo.ProductName); - Console.WriteLine("Version " + asmInfo.ProductVersion); - Console.WriteLine(asmInfo.LegalCopyright); - Console.WriteLine(""); + if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { + // Banner + var location = Assembly.GetEntryAssembly().Location; + if (location == "") // Single file executables don't have an assembly location + location = Path.Join(AppContext.BaseDirectory, "Il2CppInspector.exe"); + + var asmInfo = FileVersionInfo.GetVersionInfo(location); + Console.WriteLine(asmInfo.ProductName); + Console.WriteLine("Version " + asmInfo.ProductVersion); + Console.WriteLine(asmInfo.LegalCopyright); + Console.WriteLine(""); + } // Safe plugin manager load try {