Windows storage spaces (#871)
This commit is contained in:
@@ -20,10 +20,13 @@ public static class OperatingSystem
|
||||
{
|
||||
// The operating system doesn't change during execution so let's query it just one time.
|
||||
PlatformID platform = Environment.OSVersion.Platform;
|
||||
Version version = Environment.OSVersion.Version;
|
||||
IsUnix = platform is PlatformID.Unix or PlatformID.MacOSX;
|
||||
|
||||
if (Environment.Is64BitOperatingSystem)
|
||||
Is64Bit = true;
|
||||
|
||||
IsWindows8OrGreater = !IsUnix && ((version.Major == 6 && version.Minor >= 2) || version.Major > 6);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -35,4 +38,9 @@ public static class OperatingSystem
|
||||
/// Gets information about whether the current system is Unix based.
|
||||
/// </summary>
|
||||
public static bool IsUnix { get; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns true if the current system is Windows 8 or a more recent Windows version
|
||||
/// </summary>
|
||||
public static bool IsWindows8OrGreater { get; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user