Skip to content

ci: Fix Ghostty zig compilation on macOS 26 runners - #803

Closed
pacificleo wants to merge 199 commits into
supabitapp:mainfrom
pacificleo:fix-zig-macos26-ci
Closed

ci: Fix Ghostty zig compilation on macOS 26 runners#803
pacificleo wants to merge 199 commits into
supabitapp:mainfrom
pacificleo:fix-zig-macos26-ci

Conversation

@pacificleo

Copy link
Copy Markdown

Replaces the mise-provided zig 0.15.2 with the Homebrew-patched zig@0.15.2 bottle. The official 0.15.2 binaries fail to compile their own build_runner natively on newer macOS SDKs (macOS 15/26), which broke make build-ghostty-xcframework in CI.

pacificleo and others added 30 commits March 2, 2026 20:53
- Refactored OpenWorktreeAction from an enum to a struct to allow custom application paths.
- Added CustomWorktreeAction to GlobalSettings to store user-defined app integrations.
- Created AppLauncherSettingsView allowing users to toggle built-in app visibility and add their own .app applications via NSOpenPanel.
- Ensured Info.plist contains CFBundleName and CFBundleDisplayName to accurately capitalize the app name as CherryLily.
- Configure SUFeedURL to fetch appcast directly from GitHub Releases asset.
- Update GitHub action to point generated URLs to GitHub instead of custom domain proxy.
- Switch hardcoded repository references to pacificleo/prs-code.
Set PRODUCT_NAME to CherryLily instead of $(TARGET_NAME) so the
menu bar and .app bundle use proper capitalization. Updated CI
workflows and test host paths accordingly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Port of supabitapp/supacode@04c23ff. When no local .cherrylily.json
exists, settings fall back to global SettingsFile instead of migrating
to a local file. Saves only write locally if a local file already exists.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Port of supabitapp/supacode@186a2f3 and @23d124e. Adds release and
debug entitlements files mirroring Ghostty permissions (audio, camera,
contacts, calendar, location, photos, apple events). Debug adds
disable-library-validation. CI re-signing now preserves entitlements
with verification. Dev builds allow code signing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Port of supabitapp/supacode@01fed34, @b635d1a, @a4705ed, @dc49263,
@d0a1174. Adds help text in Appearance settings explaining Ghostty
terminal theming via config file. Fixes linter indentation issue in
ContentView and notification delegate conformance.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Port of supabitapp/supacode@ec0075b, @511dd2f, @ad792c2, @6874707.
Adds configurable worktree base directories at global and per-repo
levels. Users can set a custom base directory in settings (global
default) and override per repository. Includes path normalization,
settings sync, UI fields, and comprehensive tests.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Port of supabitapp/supacode@4f11a34 and @c1aace0. Adds Ghostty terminal
commands to the command palette, with dynamic keyboard shortcuts from
GhosttyShortcutManager. Ghostty items are demoted below native items
via priority tier offset. Includes performBindingAction terminal command
and comprehensive tests.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Update @testable import to use CherryLily (capitalized module name).
Fix preferredDefault() call to pass settings parameter. Fix remaining
createWorktree call sites to use new baseDirectory/copyFiles signature.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds a persisted toggle in the sidebar footer to switch between manual
ordering and alphabetical sorting. When enabled, all non-main worktrees
are flattened (ignoring pin sections) and sorted case-insensitively by
name. Drag-to-reorder is disabled while alphabetical sort is active.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The bell icon on worktree rows was only triggered by OSC desktop
notifications, missing terminal bell signals (e.g. Claude Code waiting
for input). Wire GHOSTTY_ACTION_RING_BELL through onBellRang callback
to appendNotification so background worktrees show the bell indicator.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Shortcut hints (e.g. ⌃1, ⌃4) shown when holding Command/Control can be
distracting. Add showShortcutHints toggle (default: off) under General >
Keyboard in settings. CommandKeyObserver respects the isEnabled flag and
suppresses isPressed when disabled.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When changing appearance mode (light/dark), only the color scheme hint
was sent to Ghostty but the config was never reloaded. This meant
theme variants (e.g. theme = light:X,dark:Y) were not applied. Now
triggers a full config reload after setting the color scheme so Ghostty
re-evaluates the theme setting.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add build-release and install-release-build Makefile targets that build
with Release optimizations but without code signing, for local testing
with full performance.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When a task is running and a bell notification arrives, the spinner was
hiding the bell icon via opacity. Now the spinner is suppressed when
there are unread notifications so the bell icon is always visible.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Required for Xcode 26 compatibility — earlier pinned revision (1.23.1)
fails to compile against Swift 6.3 due to WritableKeyPath Sendable
requirements that were addressed upstream in 1.24.x.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Toolbar leading slot becomes browser-style ⟨ / ⟩ chevrons backed by an
in-memory NavigationHistory of (worktreeID, tabID) entries. ⌘← / ⌘→
shortcuts; tooltips show the destination worktree name. Each sidebar
worktree click, tab bar click, keyboard switch, or programmatic jump
records an entry; new selections clear the forward stack; back/forward
skips and discards entries whose worktree or tab no longer exists.

The branch rename action moves to a "Rename Branch…" item in each
sidebar row's context menu and remains accessible via ⌘M on the focused
worktree. Renamed WorktreeDetailTitleView.swift to RenameBranchPopover.swift
since the popover is the only piece kept.

Implementation:
- NavigationHistory value type in Domain with idempotent record() so
  back/forward effects don't re-push their own destinations.
- AppFeature.State holds the history; AppFeature observes existing
  selectedWorktreeChanged delegate plus a new tab-level event.
- New TerminalClient command focusTab and event tabFocusChanged
  (driven from TerminalTabManager.selectedTabId.didSet so split focus
  changes inside a tab don't pollute history).
- New TerminalClient queries currentTabID and tabExists so the reducer
  can stamp entries and validate destinations without reaching past
  the client boundary.

Tests: NavigationHistoryTests covers the value type;
AppFeatureNavigationHistoryTests covers recording, navigation effects,
and stale-entry skipping.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Add VSCodium (com.vscodium) to the editor selection list, allowing users
to open worktrees directly in VSCodium from the supacode interface.
* Fix notification settings alert presentation

* Present settings alerts from root view
Registers `ApplePressAndHoldEnabled = false` in UserDefaults on launch,
matching what Ghostty does upstream. This prevents the macOS accent
character picker from appearing when holding down a key, allowing
key repeat to work correctly in the terminal.

Fixes supabitapp#152

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
prashantwason and others added 27 commits June 3, 2026 22:51
Replace the worktree toolbar's 'Open in…' split-button + dropdown with a row
of icon-only buttons for the apps a user pins in Settings → App Launcher.

- GlobalSettings: add ordered pinnedToolbarActions; decode seeds Finder +
  default editor for users upgrading from before pinning existed.
- OpenWorktreeAction: pinnedToolbarCases resolver (installed-filtered, ordered)
  and per-custom-app icons (fixes the shared 'custom' icon-cache collision).
- SettingsFeature: pin/unpin/reorder actions; App Launcher settings reworked
  into a pin manager. Updates apply live (no restart) via @shared(.settingsFile).
- Toolbar renders icon buttons firing the existing .openWorktree action; the
  Run button is unchanged.
- Remove the now-orphaned default-open machinery: openActionSelection, the
  per-repo default, the 'Open Worktree' menu command, and its ⌘ shortcut
  (AppShortcuts.openFinder case kept for override decode-compat).
- Tests for seeding/migration, pinnedToolbarCases, pin/reorder, and updated
  existing settings/default-editor tests.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replaces the Open-in dropdown with pinned app icons in the toolbar;
adds pinned-apps to GlobalSettings + SettingsFeature pin actions and an
AppLauncher settings UI.

Conflict: AppFeatureDefaultEditorTests — apps tweaked the now-removed
repositoryLocalSettingsOverrideGlobalRepositorySettings test; kept HEAD's
deletion of it (local per-repo settings were removed in b48baa7).

Build clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the blind per-worktree polling loop in WorktreeInfoWatcherManager
with a per-worktree FSEvents content watcher. File-system events go
through GitIgnorePrefixMatcher to suppress .git/ internals, then trigger
the existing debounce → .filesChanged path. The .git/HEAD DispatchSource
remains for .branchChanged. updateLineChangeSchedule no longer starts a
repeating timer; deferred worktrees are unblocked on selection instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
lineChangeTasks was never written to after the polling loop was removed,
updateRepeatingTask had zero callers, RepeatingTaskRequest was only used
by updateRepeatingTask, and forceReschedule was evaluated only inside
updateRepeatingTask. All cancel/clear calls on the always-empty dict were
no-ops. scheduleFilesChanged's dead updateLineChangeSchedule(immediate:false)
call is also removed.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replaces the fixed 15s retry interval with capped exponential backoff
(15s → 30s → 60s → ... → 300s max) to avoid spinning at a fixed rate
when GitHub integration is unavailable.
… cadence

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replaces polling with FSEventStream-driven line-change (+/- pill) and
refs-triggered PR refresh; adds GitCapabilities fsmonitor detection,
GitClient.headSHA/gitCommonDir, GitIgnorePrefixMatcher noise prefilter,
and SHA-dedupe + exponential GitHub-recovery backoff.

Conflict: RepositoriesFeature — both this branch and the already-merged
PERF 3.3 independently added a GitHub-recovery backoff helper. Kept
gitstatusd's tested `githubRecoveryBackoff` (it has a unit test) and
removed the duplicate untested `githubRecoveryDelay`.

Build clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Documents that tests spawning real Ghostty login shells still append
fixtures to the developer's ~/.zsh_history, with root cause, the
partial-fix history, and the preferred fix (mock the surface).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The 0.7.6 app segfaulted on open (SIGSEGV on the
app.supabit.cherrylily.fsevents queue, objc_msgSend on a path-string
address). Root cause: the FSEventStream was created WITHOUT
kFSEventStreamCreateFlagUseCFTypes, so the callback's `eventPaths` is a
raw C `char **`. `unsafeBitCast(eventPaths, to: NSArray.self) as? [String]`
then bridged path-string bytes as ObjC objects -> bad access.

- Add kFSEventStreamCreateFlagUseCFTypes so eventPaths is a
  CFArray<CFString> that bridges to [String] safely.
- Harden lifetime: give the FSEventStreamContext real retain/release
  callbacks so Core Services keeps the source alive for the stream's
  lifetime (the previous passUnretained + nil retain/release could
  dereference a freed source if it was dropped before stop()).

Not caught by tests: WorktreeInfoWatcherManagerTests use a stub event
source, so the real FSEventStream path is never exercised.

Verified: built app launches and survives file events without crashing.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This explicitly overrides the native macOS list selection behavior to preserve a permanent blue highlight for the currently selected worktree, even when the window or sidebar loses focus.
Zig 0.15.2 binaries from mise have a known bug when compiling natively on newer macOS SDKs (macOS 15/26), causing `zig build` to fail to link compiler_rt (undefined symbol _abort and ___isPlatformVersionAtLeast).
The Homebrew bottle for zig@0.15 is patched and avoids this bug. We now install it via Homebrew directly in CI and remove it from mise to fix Ghostty builds.
@pacificleo pacificleo closed this Aug 19, 2026
@github-actions github-actions Bot added the invalid Does not meet the contribution policy; closed automatically after a few days if left inactive. label Aug 19, 2026
@github-actions

Copy link
Copy Markdown

Thanks for the pull request. It doesn't meet the contribution policy yet, so I've labeled it invalid. Please address the following, then push an update:

  • No linked issue. Add a line like Closes #123 to the description, pointing at an open issue in this repository.
  • A commit is authored or co-authored by an AI agent. A human must be the author of record: re-author the commits under your own name (reset the author, or drop the Co-authored-by: trailer). Using AI tools is welcome, and you are encouraged to disclose them in the description.

Nothing needs to be redone. A pull request left invalid is closed automatically after a few days of inactivity. See CONTRIBUTING.md for the full flow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

invalid Does not meet the contribution policy; closed automatically after a few days if left inactive.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants