diff --git a/packages/opencode/script/build.ts b/packages/opencode/script/build.ts index 5704f22b07..c21bd7c734 100755 --- a/packages/opencode/script/build.ts +++ b/packages/opencode/script/build.ts @@ -137,12 +137,12 @@ for (const item of targets) { const bunfsRoot = item.os === "win32" ? "B:/~BUN/root/" : "/$bunfs/root/" const workerRelativePath = path.relative(dir, parserWorker).replaceAll("\\", "/") - // Use fork bun runtime for Windows targets - // Set BUN_FORK_VERSION env var (e.g. "1.3.9-opencode") to use anomalyco/bun fork binaries - const forkVersion = process.env.BUN_FORK_VERSION - if (item.os === "win32" && forkVersion) { + // Use anomalyco/bun fork for Windows targets (includes Ctrl+C fix from PR #25876) + // https://github.com/anomalyco/bun/releases/tag/v1.3.9-opencode.1 + const BUN_FORK_VERSION = "1.3.9-opencode.1" + if (item.os === "win32") { const variant = item.avx2 === false ? "bun-windows-x64-baseline" : "bun-windows-x64" - process.env.BUN_COMPILE_TARGET_TARBALL_URL = `https://github.com/anomalyco/bun/releases/download/v${forkVersion}/${variant}.tgz` + process.env.BUN_COMPILE_TARGET_TARBALL_URL = `https://github.com/anomalyco/bun/releases/download/v${BUN_FORK_VERSION}/${variant}.tgz` } else { delete process.env.BUN_COMPILE_TARGET_TARBALL_URL }