Skip to content

Commit 80fa40d

Browse files
committed
fix: ensure shell option is set for npm commands on Windows
1 parent 5e71100 commit 80fa40d

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

scripts/check-memory.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ try {
4646
execFileSync("npm", ["run", "build:native"], {
4747
stdio: "inherit",
4848
env: cleanEnv,
49+
shell: true, // Required on Windows where npm is npm.cmd
4950
});
5051
console.log(color(colors.GREEN, "✓ Native module ready"));
5152
} catch (error) {
@@ -186,6 +187,7 @@ if (os.platform() === "linux") {
186187
execFileSync("npm", ["run", "build:native"], {
187188
stdio: "inherit",
188189
env: cleanEnv,
190+
shell: true, // Required on Windows where npm is npm.cmd
189191
});
190192
console.log(color(colors.GREEN, "✓ Native module restored"));
191193
} catch (rebuildError) {

0 commit comments

Comments
 (0)