Problem
After running worktree setup, the WorktreeRunner.app bundle is installed at ~/Applications/WorktreeRunner.app and lsregister registers the worktree:// URL scheme. However, the app bundle is not code-signed, so macOS Gatekeeper removes or invalidates it — typically after a reboot or a Launch Services database reset — causing the worktree:// scheme to stop working and macOS to show the "No application set to open this URL" dialog.
Steps to Reproduce
- Run
worktree setup
- Confirm
worktree scheme status reports installed
- Reboot the machine
- Click a
worktree:// deep link
- macOS shows "There is no application set to open the URL"
Root Cause
osacompile produces an unsigned .app bundle. Gatekeeper quarantines or evicts unsigned app bundles from ~/Applications/ over time.
Possible Fixes
- Ad-hoc code sign the generated bundle after
osacompile using codesign --sign - --force --deep (ad-hoc signing satisfies Gatekeeper for locally-built tools without requiring a paid Apple Developer certificate)
- Re-register on login via a
launchd plist in ~/Library/LaunchAgents/ that runs worktree scheme install at login, so the scheme is re-registered automatically if it gets evicted
- Both approaches can be combined for maximum resilience
Problem
After running
worktree setup, theWorktreeRunner.appbundle is installed at~/Applications/WorktreeRunner.appandlsregisterregisters theworktree://URL scheme. However, the app bundle is not code-signed, so macOS Gatekeeper removes or invalidates it — typically after a reboot or a Launch Services database reset — causing theworktree://scheme to stop working and macOS to show the "No application set to open this URL" dialog.Steps to Reproduce
worktree setupworktree scheme statusreports installedworktree://deep linkRoot Cause
osacompileproduces an unsigned.appbundle. Gatekeeper quarantines or evicts unsigned app bundles from~/Applications/over time.Possible Fixes
osacompileusingcodesign --sign - --force --deep(ad-hoc signing satisfies Gatekeeper for locally-built tools without requiring a paid Apple Developer certificate)launchdplist in~/Library/LaunchAgents/that runsworktree scheme installat login, so the scheme is re-registered automatically if it gets evicted