Find Mac OSX version installed using AppleScript
问题 How can I find which version of OSX is installed on my Mac by using AppleScript? I want to install an app programatically and run different pkg files based on the version. Thanks 回答1: I'm not on a Mac, so there may be a better way to do this, but the first approach that comes to mind is just executing a shell command to query the OS version. http://developer.apple.com/technotes/tn2002/tn2065.html#TNTAG2 http://developer.apple.com/DOCUMENTATION/Darwin/Reference/ManPages/man1/sw_vers.1.html