peterkahl / apple-os-x-build-version
Associative array of OS X build and version codes that can be used in various ways.
Installs: 69 998
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: >=5.3.0
- dev-master
- v43.9
- v43.8
- v43.7
- v43.6
- v43.5
- v43.4
- v43.3
- v43.2
- v43.1
- v43.0
- v42.0
- v41.0
- v40.0
- v39.0
- v38.0
- v37.2
- v37.1
- v37.0
- v36.0
- v35.1
- v35.0
- v34.0
- v33.0
- v32.0
- v31.0
- v30.0
- v29.0
- v28.0
- v27.0
- v26.0
- v25.0
- v24.0
- v23.0
- v22.0
- v21.0
- v20.0
- v19.0
- v18.0
- v16.0
- v15.0
- v14.0
- v13.0
- v12.0
- v11.1
- v11.1a
- v11.0
- v10.0
- v9.0
- v8.0
- v7.0
- v6.1
- v6.0
- v5.0
- v4.0
- v3.0
- v2.0
- v1.0
This package is auto-updated.
Last update: 2021-01-02 17:56:44 UTC
README
Associative array of OS X build and version codes that can be used in various ways. Uses fuzzy matching.
Usage
use peterkahl\OSXbuild\OSXbuild; # Takes OS X build code and returns corresponding OS X version. echo '16E195 ............ '. OSXbuild::getVersion('16E195') ."\n"; # Let's try build code that's not in our array: echo '15A299 ............ '. OSXbuild::getVersion('15A299') ."\n"; /* 16E195 ............ 10.12.4 15A299 ............ 10.11 */ # Are build/version data outdated? Older than 30 days: if (OSXbuild::GetDataTimestamp() < time() - 30*86400) { echo 'OUTDATED'; # Send email to admin to do something? } # Returns associative array of OS X versions. $array = OSXbuild::getArray(); # Returns a randomly chosen OS X Calendar User Agent string. echo OSXbuild::getCalendarUA(); # Mac+OS+X/10.12.2 (16C67) CalendarAgent/384 # Optionally, you can specify a minimum version of OS X (to get random User Agent string). # Argument must be a string in format 'MAJOR.MINOR' (1 dot only.) echo OSXbuild::getCalendarUA('10.10');