From d3e43437a00cfe64790cc60c9c8aa82c85f520c3 Mon Sep 17 00:00:00 2001 From: Olcan Date: Thu, 5 Jun 2025 13:02:56 -0700 Subject: use execSync (vs spawnSync) so launch fails if build_sandbox fails; tweaks in build_sandbox to fix some shellcheck warnings, and to simplify the logic slightly (#767) --- packages/cli/src/utils/sandbox.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'packages/cli/src') diff --git a/packages/cli/src/utils/sandbox.ts b/packages/cli/src/utils/sandbox.ts index 2b672ef5..5038e702 100644 --- a/packages/cli/src/utils/sandbox.ts +++ b/packages/cli/src/utils/sandbox.ts @@ -308,9 +308,8 @@ export async function start_sandbox(sandbox: string) { console.error(`using ${projectSandboxDockerfile} for sandbox`); buildArgs += `-s -f ${path.resolve(projectSandboxDockerfile)} -i ${image}`; } - spawnSync(`cd ${gcRoot} && scripts/build_sandbox.sh ${buildArgs}`, { + execSync(`cd ${gcRoot} && scripts/build_sandbox.sh ${buildArgs}`, { stdio: 'inherit', - shell: true, env: { ...process.env, GEMINI_SANDBOX: sandbox, // in case sandbox is enabled via flags (see config.ts under cli package) -- cgit v1.2.3