I want get MacOS version using ProcessInfo.processInfo.operatingSystemVersion.majorVersion, but for MacOS Monterey 12.0 Beta, I see it returns 10.16, how can I know the MacOS is Monterey?
How to get MacOS version Beta
What you describe is surprising.
majorVersion should be an integer(10, 11, 12), not 10.16.
-
var majorVersion: Int
The major release number, such as 10 in version 10.9.3.
-
var minorVersion: Int
The minor release number, such as 9 in version 10.9.3.
-
var patchVersion: Int
The update release number, such as 3 in version 10.9.3.
Could you show the code where you call for it ?
MacOS 10 ended at 10.15. Further beta (11ß) were sometimes named 10.16.
But this is surprising for 12ß. Is it a remaining string left by mistake ?