fix: cover Windows exe argv (#1480) (thanks @Takhoffman)

This commit is contained in:
Peter Steinberger
2026-01-23 04:45:23 +00:00
parent ea7791f2b9
commit ee24cfb58e
4 changed files with 19 additions and 0 deletions

View File

@@ -116,6 +116,7 @@ if (!shouldBuild()) {
} else {
logRunner("Building TypeScript (dist is stale).");
const pnpmArgs = ["exec", compiler, ...projectArgs];
// On Windows, pnpm is a .cmd shim, so use cmd.exe for reliable resolution.
const buildCmd = process.platform === "win32" ? "cmd.exe" : "pnpm";
const buildArgs =
process.platform === "win32" ? ["/d", "/s", "/c", "pnpm", ...pnpmArgs] : pnpmArgs;