This commit is contained in:
Ayush Ojha 2026-01-30 11:23:13 -05:00 committed by GitHub
commit f962dfda70
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -80,11 +80,13 @@ export async function runCommandWithTimeout(
} }
const stdio = resolveCommandStdio({ hasInput, preferInherit: true }); const stdio = resolveCommandStdio({ hasInput, preferInherit: true });
const isWindows = process.platform === "win32";
const child = spawn(argv[0], argv.slice(1), { const child = spawn(argv[0], argv.slice(1), {
stdio, stdio,
cwd, cwd,
env: resolvedEnv, env: resolvedEnv,
windowsVerbatimArguments, windowsVerbatimArguments,
shell: isWindows,
}); });
// Spawn with inherited stdin (TTY) so tools like `pi` stay interactive when needed. // Spawn with inherited stdin (TTY) so tools like `pi` stay interactive when needed.
return await new Promise((resolve, reject) => { return await new Promise((resolve, reject) => {