diff --git a/src/chocolatey/infrastructure/platforms/Platform.cs b/src/chocolatey/infrastructure/platforms/Platform.cs index 253612edf5..558284234e 100644 --- a/src/chocolatey/infrastructure/platforms/Platform.cs +++ b/src/chocolatey/infrastructure/platforms/Platform.cs @@ -120,7 +120,15 @@ private static string GetWindowsVersionName(Version version) switch (majorMinor) { case "10.0": - name = isServer ? "Windows Server 2016" : "Windows 10"; + if (isServer) + { + name = (version.Build < 20348) ? (version.Build < 17763) ? + "Windows Server 2016" : "Windows Server 2019" : "Windows Server 2022"; + } + else + { + name = (version.Build < 22000) ? "Windows 10" : "Windows 11"; + } break; case "6.4": name = isServer ? "Windows Server 2016" : "Windows 10";