mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-08-29 03:44:06 +08:00
fix(vscode): include kilo-sandbox-mutation-worker.js in extension bundle (#11926)
* fix(vscode): include kilo-sandbox-mutation-worker.js in extension bundle The release build script (packages/kilo-vscode/script/build.ts) was missing the copyKiloSandboxWorker call, causing the sandbox mutation worker file to be absent from .vsix packages. All sandbox-enclosed file operations (write, copy, rename, chmod, etc.) would fail with a "Module not found" error because the kilo binary could not spawn the required worker process. Closes #11925 * chore(vscode): fix import formatting --------- Co-authored-by: marius-kilocode <marius@kilocode.ai>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"kilo-code": patch
|
||||
---
|
||||
|
||||
Fix missing kilo-sandbox-mutation-worker.js in VS Code extension bundle, which caused sandboxed file operations to fail with "Module not found".
|
||||
@@ -2,7 +2,11 @@
|
||||
import { $ } from "bun"
|
||||
import { join } from "node:path"
|
||||
import { existsSync, mkdirSync, rmSync, chmodSync } from "node:fs"
|
||||
import { copySandboxResources, copyTreeSitterResources } from "../src/services/cli-backend/cli-resources"
|
||||
import {
|
||||
copyKiloSandboxWorker,
|
||||
copySandboxResources,
|
||||
copyTreeSitterResources,
|
||||
} from "../src/services/cli-backend/cli-resources"
|
||||
import { ensureFfmpegForTarget } from "./ffmpeg-helper"
|
||||
|
||||
const packageJsonPath = join(import.meta.dir, "..", "package.json")
|
||||
@@ -78,6 +82,7 @@ for (const config of targets) {
|
||||
await $`cp ${sourceBinary} ${targetBinary}`
|
||||
await copyTreeSitterResources(sourceBinary, targetBinary)
|
||||
await copySandboxResources(sourceBinary, targetBinary)
|
||||
await copyKiloSandboxWorker(sourceBinary, targetBinary)
|
||||
|
||||
if (config.binary !== "kilo.exe") {
|
||||
chmodSync(targetBinary, 0o755)
|
||||
|
||||
Reference in New Issue
Block a user