From 15d71e2dc0258a5d4ab8e1dc4e2b2b8f02ed874a Mon Sep 17 00:00:00 2001 From: Kelvin Amoaba <97001695+AmoabaKelvin@users.noreply.github.com> Date: Sat, 7 Nov 2026 02:32:34 +0000 Subject: [PATCH] =?UTF-8?q?fix(homebrew):=20keep=20macOS=2013.0=E2=80=9313?= =?UTF-8?q?.3=20Macs=20on=20the=20Orca=20they=20can=20open=20(#39264)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Orca now needs macOS 13.4, but depends_on can only say Ventura, and Homebrew 7 upgrades auto_updates casks by default. A preflight step refuses the upgrade below 13.4 so Homebrew reverts to the installed app. --- Casks/orca.rb | 11 ++++++++++- Casks/orca@rc.rb | 9 +++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/Casks/orca.rb b/Casks/orca.rb index 39906751a79..51787cde42f 100644 --- a/Casks/orca.rb +++ b/Casks/orca.rb @@ -15,7 +15,7 @@ cask "orca" do strategy :github_latest end - # Let the in-app updater own updates; Homebrew skips auto_updates unless --greedy. + # Let the in-app updater own updates between brew upgrades. auto_updates true conflicts_with cask: "orca@rc" depends_on macos: :ventura @@ -25,6 +25,15 @@ cask "orca" do # Expose the symlink-resolving bundled CLI on PATH so headless hosts can use orca serve without the in-app installer. binary "#{appdir}/Orca.app/Contents/Resources/bin/orca" + # depends_on can't say 13.4, and Homebrew upgrades auto_updates casks past the in-app updater's macOS gate. + preflight_steps do + run "/bin/sh", args: [ + "-c", + 'case "$(/usr/bin/sw_vers -productVersion)" in 13|13.[0-3]|13.[0-3].*) ' \ + 'echo "Orca needs macOS 13.4 or later. Update macOS to upgrade Orca." >&2; exit 1;; esac', + ] + end + # Zap app-created ~/.orca and Electron userData for a clean uninstall. zap trash: [ "~/.orca", diff --git a/Casks/orca@rc.rb b/Casks/orca@rc.rb index 42ccb7dd19f..61b1aeb268a 100644 --- a/Casks/orca@rc.rb +++ b/Casks/orca@rc.rb @@ -36,6 +36,15 @@ cask "orca@rc" do # Expose the symlink-resolving bundled CLI on PATH so headless hosts can use orca serve without the in-app installer. binary "#{appdir}/Orca.app/Contents/Resources/bin/orca" + # depends_on can't say 13.4, and Homebrew upgrades auto_updates casks past the in-app updater's macOS gate. + preflight_steps do + run "/bin/sh", args: [ + "-c", + 'case "$(/usr/bin/sw_vers -productVersion)" in 13|13.[0-3]|13.[0-3].*) ' \ + 'echo "Orca needs macOS 13.4 or later. Update macOS to upgrade Orca." >&2; exit 1;; esac', + ] + end + # Zap app-created ~/.orca and Electron userData for a clean uninstall. zap trash: [ "~/.orca",