opencode
opencode copied to clipboard
fix(upgrade): handle brew tap migration from sst/tap and core
Fixes #6841
The Homebrew tap was renamed from sst/tap to anomalyco/tap. Users on old versions had code checking for sst/tap, but their install was from anomalyco/tap (or vice versa), causing upgrade to fallback to core and fail with "formulae from different taps cannot be installed" error. You can see the error here: https://github.com/anomalyco/opencode/issues/6841#issuecomment-3733460171
At the same time, the homebrew core formula got throttled so we are now offering users to switch to the anomalyco/tap to get more consistent updates.
This PR:
- Detects all brew variants:
anomalyco/tap,sst/tap, and core - Prompts users to migrate to
anomalyco/tapwith clear reasoning - Shows exact commands before running so users can run manually if needed
Migration prompts:
- sst/tap users: "You have the old sst/tap formula installed. The tap has been renamed to anomalyco/tap."
- core users: "You are on the homebrew core formula, which updates every ~10 versions. The anomalyco/tap formula updates on every release."