You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
728 B
36 lines
728 B
using System;
|
|
|
|
namespace NzbDrone.Common.EnvironmentInfo
|
|
{
|
|
public static class OsInfo
|
|
{
|
|
|
|
public static Version Version
|
|
{
|
|
get
|
|
{
|
|
OperatingSystem os = Environment.OSVersion;
|
|
Version version = os.Version;
|
|
|
|
return version;
|
|
}
|
|
}
|
|
|
|
public static bool IsMono
|
|
{
|
|
get
|
|
{
|
|
return Type.GetType("Mono.Runtime") != null;
|
|
}
|
|
}
|
|
|
|
public static bool IsLinux
|
|
{
|
|
get
|
|
{
|
|
int p = (int)Environment.OSVersion.Platform;
|
|
return (p == 4) || (p == 6) || (p == 128);
|
|
}
|
|
}
|
|
}
|
|
} |