diff --git a/script/bottle b/script/bottle index f163bc0..66c7cbc 100755 --- a/script/bottle +++ b/script/bottle @@ -17,8 +17,8 @@ BOTTLE_DIR="$BUILD_DIR/bottles" VERSION=$(script/version) ROOT_URL="https://github.com/mas-cli/mas/releases/download/v${VERSION}" -# Supports macOS versions 11 (arm64 & x86_64), 10.15, 10.14, 10.13, 10.12, 10.11 -OS_NAMES=(arm64_big_sur big_sur catalina mojave high_sierra sierra el_capitan) +# Supports macOS 10.11 and later +OS_NAMES=(arm64_monterey monterey arm64_big_sur big_sur catalina mojave high_sierra sierra el_capitan) # Semantic version number split into a list using Ugly, bash 3 compatible syntax IFS=" " read -r -a CURRENT_OS_VERSION <<<"$(sw_vers -productVersion | sed 's/\./ /g'))" @@ -28,7 +28,13 @@ CURRENT_OS_VERSION_MINOR=${CURRENT_OS_VERSION[1]} echo "CURRENT_OS_VERSION_MAJOR: $CURRENT_OS_VERSION_MAJOR" echo "CURRENT_OS_VERSION_MINOR: $CURRENT_OS_VERSION_MINOR" -if [[ ${CURRENT_OS_VERSION_MAJOR} == "11" ]]; then +if [[ ${CURRENT_OS_VERSION_MAJOR} == "12" ]]; then + if [[ "x86_64" == "$(uname -m)" ]]; then + CURRENT_PLATFORM=monterey + else + CURRENT_PLATFORM=arm64_monterey + fi +elif [[ ${CURRENT_OS_VERSION_MAJOR} == "11" ]]; then # Big Sur if [[ "x86_64" == "$(uname -m)" ]]; then CURRENT_PLATFORM=big_sur