MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / mac_ver

Function mac_ver

tools/python-3.11.9-amd64/Lib/platform.py:436–453  ·  view source on GitHub ↗

Get macOS version information and return it as tuple (release, versioninfo, machine) with versioninfo being a tuple (version, dev_stage, non_release_version). Entries which cannot be determined are set to the parameter values which default to ''. All tuple entr

(release='', versioninfo=('', '', ''), machine='')

Source from the content-addressed store, hash-verified

434
435
436def mac_ver(release='', versioninfo=('', '', ''), machine=''):
437
438 """ Get macOS version information and return it as tuple (release,
439 versioninfo, machine) with versioninfo being a tuple (version,
440 dev_stage, non_release_version).
441
442 Entries which cannot be determined are set to the parameter values
443 which default to ''. All tuple entries are strings.
444 """
445
446 # First try reading the information from an XML file which should
447 # always be present
448 info = _mac_ver_xml()
449 if info is not None:
450 return info
451
452 # If that also doesn't work return the default values
453 return release, versioninfo, machine
454
455def _java_getprop(name, default):
456

Callers 1

platformFunction · 0.85

Calls 1

_mac_ver_xmlFunction · 0.85

Tested by

no test coverage detected