Skip to content

build(macos): bundle and sign opencode-cli in macOS app - #1309

Merged
thdxr merged 2 commits into
devfrom
feat/macos-bundle-cli
Nov 26, 2026
Merged

thdxr merged 2 commits into
devfrom
feat/macos-bundle-cli

Conversation

@Hona

@Hona Hona commented Nov 26, 2026

Copy link
Copy Markdown
Member

Enables bundled Contents/Resources/opencode-cli + opencode-cli.version on macOS builds (completing #1303 across all three platforms) and signs it inside-out with official Desktop's CLI entitlements.

  • Bundled CLI entitlements (.github/release/opencode-rune-cli.entitlements): Matches official anomalyco/opencode .github/release/entitlements/desktop-cli.plist (com.apple.security.cs.allow-jit + com.apple.security.cs.disable-library-validation so the Bun CLI can run JIT and load bun-pty under hardened runtime).
  • Release signing (.github/release/opencode-rune-sign-macos.sh): Permits Contents/Resources/opencode-cli in the strict Mach-O allowlist and signs it inside-out with opencode-rune-cli.entitlements before signing the .app.
  • macOS build script (apps/desktop/scripts/build-app.sh): Flips OPENCODE_RUNE_BUNDLE_CLI default from 0 to 1 (opt-out with 0). apps/desktop/scripts/validate-app.sh already validates its arch, TeamIdentifier, and opencode-cli.version.

@Hona
Hona requested a review from thdxr as a code owner November 26, 2026 09:17
@Hona
Hona force-pushed the feat/macos-bundle-cli branch from e3f6551 to 18db214 Compare November 26, 2026 09:17

@thdxr thdxr left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

entitlements and signing allowlist look good. flipped OPENCODE_RUNE_BUNDLE_CLI on line 284 of build-app.sh (it still defaulted to 0 so fetch-cli.mjs wasn't running) and confirmed macOS PR build now stages opencode-cli cleanly.

@thdxr
thdxr merged commit 2c2e535 into dev Nov 26, 2026
7 checks passed
@thdxr
thdxr deleted the feat/macos-bundle-cli branch November 26, 2026 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants