From a23b83314ec82dca5976a412e60e27f154ea0451 Mon Sep 17 00:00:00 2001 From: Icarus Wings <10465470+TheIcarusWings@users.noreply.github.com> Date: Sun, 14 Jun 2026 19:52:22 +0100 Subject: [PATCH] fix(desktop): mac start:desktop crash from rewritten framework symlinks (#3058) --- apps/desktop/scripts/electron-launcher.mjs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/desktop/scripts/electron-launcher.mjs b/apps/desktop/scripts/electron-launcher.mjs index 1fc956b39dc9ee74c207930243fc261376300db6..bc1fabae960b52929632d94e3e1dff07c8da8b15 100644 --- a/apps/desktop/scripts/electron-launcher.mjs +++ b/apps/desktop/scripts/electron-launcher.mjs @@ -30,7 +30,7 @@ export const APP_BUNDLE_ID = isDevelopment ? `com.t3tools.t3code.dev.${devBundleIdSuffix || "local"}` : "com.t3tools.t3code"; const APP_PROTOCOL_SCHEMES = isDevelopment ? ["t3code-dev"] : ["t3code"]; -const LAUNCHER_VERSION = 10; +const LAUNCHER_VERSION = 11; const defaultIconPath = join(desktopDir, "resources", "icon.icns"); const developmentMacIconPngPath = join(repoRoot, "assets", "dev", "blueprint-macos-1024.png"); @@ -295,7 +295,11 @@ function buildMacLauncher(electronBinaryPath) { } rmSync(targetAppBundlePath, { recursive: true, force: true }); - cpSync(sourceAppBundlePath, targetAppBundlePath, { recursive: true }); + // verbatimSymlinks keeps the framework's relative symlinks intact + // (e.g. Resources -> Versions/Current/Resources). Without it cpSync + // rewrites them to absolute paths into node_modules, which escape the + // bundle and crash sandboxed helper processes (icudtl.dat not found). + cpSync(sourceAppBundlePath, targetAppBundlePath, { recursive: true, verbatimSymlinks: true }); patchMainBundleInfoPlist(targetAppBundlePath, iconPath); patchHelperBundleInfoPlists(targetAppBundlePath); if (isDevelopment) { -- 2.54.0