bail out if macOS 10.9 or lower is used during installer

This commit is contained in:
Domen Kožar 2017-01-24 19:59:55 +01:00
parent 9000150a78
commit 48d4a23aa0
No known key found for this signature in database
GPG Key ID: C2FFBCAFD2C24246
1 changed files with 7 additions and 0 deletions

View File

@ -7,6 +7,13 @@ self="$(dirname "$0")"
nix="@nix@"
cacert="@cacert@"
# macOS support for 10.10 or higher
if [[ "$(uname -s)" = "Darwin" && $(($(sw_vers -productVersion | cut -d '.' -f 2))) -lt 10 ]]; then
echo "$0: macOS $(sw_vers -productVersion) is not supported, upgrade to 10.10 or higher"
exit 1
fi
if ! [ -e "$self/.reginfo" ]; then
echo "$0: incomplete installer (.reginfo is missing)" >&2
exit 1