From 4d48f09dc778a15355a555f425c5c5a1d184cb3d Mon Sep 17 00:00:00 2001 From: Mengjuei Hsieh Date: Sun, 2 Oct 2011 20:10:08 -0700 Subject: [PATCH] Adding osx version checking --- Installer/Script.bash | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Installer/Script.bash b/Installer/Script.bash index 48a88033..d44df968 100644 --- a/Installer/Script.bash +++ b/Installer/Script.bash @@ -6,6 +6,20 @@ # 'CocoaDialog.app' # 'pic_normal.png' # +osx_version=`/usr/bin/sw_vers -productVersion | awk '{print $1}'` +case "$osx_version" in + *10\.6*) + osx_supported='yes' ;; + *10\.7*) + osx_supported='yes' ;; + *) + osx_supported='no' ;; +esac + +if [ $osx_supported == "no" ]; then + $CD bubble --debug --title "Sorry!" --text "McBoPoMoPo is only compatible with Mac OS X 10.6 and 10.7." --icon-file pic_normal.png + exit 0 +fi myLicense="Copyright (c) 2011, the Openvanilla Project