using System;
using System.Runtime.InteropServices;
namespace ShowOSConsole
{
class Program
{
static void Main(string[] args)
{
if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux))
Console.WriteLine(RuntimeInformation.OSDescription);
else if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX))
Console.WriteLine(RuntimeInformation.OSDescription);
else
Console.WriteLine(RuntimeInformation.OSDescription);
Console.WriteLine("輸入任何鍵結束");
Console.ReadKey();
}
}
}