Skip to content

an open-source alternative to the dots, bots and muses of the world, run an office of claude code/codex like agents on your laptop, sandboxes or anywhere, uses your existing subscriptions

build(mac): make notarization best-effort so it never blocks the release

Chaitanya Giri1fa84dc85435
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 42024f90..70fe9240 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -9,8 +9,9 @@ All notable changes to this project are documented here. The format is based on
## [0.1.4] — 2026-06-04
### Added
-- **Signed & notarized macOS builds.** The app now ships with a hardened-runtime
- Developer ID signature and is notarized + stapled by Apple. Because macOS binds a
+- **Signed macOS builds.** The app now ships with a hardened-runtime Developer ID
+ signature (notarization is attempted in CI and stapled when it succeeds; the build is
+ best-effort, so a notarization hiccup never blocks a release). Because macOS binds a
folder-access (TCC) grant to a stable code signature, you're now prompted for
Documents/Desktop/Downloads access **once** instead of on every agent action.
Usage-description strings explain each prompt. Signing/notarization run in CI only
diff --git a/RELEASE.md b/RELEASE.md
index ac1fee0e..abfe567e 100644
--- a/RELEASE.md
+++ b/RELEASE.md
@@ -41,10 +41,12 @@ Apple Silicon and Intel.
## First launch
-- **macOS** — the build is **signed with a Developer ID and notarized by Apple**, so it
- opens normally. The first time agents touch a folder you'll get a single macOS privacy
- prompt for Documents/Desktop/Downloads — allow it once and the grant sticks (it covers
- the `claude` agents the app spawns).
+- **macOS** — the build is **signed with a Developer ID** (hardened runtime). If macOS
+ still shows an "unidentified developer" warning on first open, right-click the app →
+ **Open** → **Open** once. After that, the first time agents touch a folder you'll get a
+ single macOS privacy prompt for Documents/Desktop/Downloads — allow it once and the
+ grant sticks (it covers the `claude` agents the app spawns), because the grant is bound
+ to the app's stable signature.
- **Windows** — not code-signed yet; SmartScreen may show "Windows protected your PC" →
**More info** → **Run anyway**.
- **Linux** — make the AppImage executable: `chmod +x Munder-Difflin-*.AppImage`, then run it.
diff --git a/build/notarize.cjs b/build/notarize.cjs
index 45eafc7a..c405a55a 100644
--- a/build/notarize.cjs
+++ b/build/notarize.cjs
@@ -44,9 +44,22 @@ exports.default = async function notarizing(context) {
: { appleId: APPLE_ID, appleIdPassword: APPLE_APP_SPECIFIC_PASSWORD, teamId: APPLE_TEAM_ID };
console.log(`[notarize] submitting ${appName}.app to Apple via notarytool (this can take a few minutes)…`);
- await notarize({ tool: 'notarytool', appPath, ...creds });
-
- console.log('[notarize] stapling ticket to the app…');
- execFileSync('xcrun', ['stapler', 'staple', appPath], { stdio: 'inherit' });
- console.log('[notarize] done — app is signed, notarized, and stapled.');
+ try {
+ await notarize({ tool: 'notarytool', appPath, ...creds });
+ console.log('[notarize] stapling ticket to the app…');
+ execFileSync('xcrun', ['stapler', 'staple', appPath], { stdio: 'inherit' });
+ console.log('[notarize] done — app is signed, notarized, and stapled.');
+ } catch (err) {
+ // Best-effort: notarization talks to Apple's servers and can fail for reasons
+ // outside the build (bad/expired app-specific password, unaccepted Developer
+ // Program agreement, Apple-side outage, a rejected submission). That must NOT
+ // sink the whole cross-platform release — the app is still Developer ID *signed*,
+ // which is what gives the stable identity macOS uses to remember folder-access
+ // grants (the one-time prompt). So we log loudly and ship the signed build;
+ // once the credentials are valid, the next release notarizes with no code change.
+ // Un-notarized = users may need a one-time right-click → Open on first launch.
+ console.warn('[notarize] ⚠️ NOTARIZATION FAILED — shipping a signed-but-unnotarized build.');
+ console.warn('[notarize] Fix the APPLE_ID / APPLE_APP_SPECIFIC_PASSWORD / APPLE_TEAM_ID secrets to enable it.');
+ console.warn(`[notarize] notarytool said:\n${err && err.message ? err.message : err}`);
+ }
};