Skip to content

Commit 101e03c

Browse files
committed
fix: use shell to run npm command
1 parent 8575810 commit 101e03c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/npm.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export async function installDeps(rootDir: string, pm: NodePM) {
2727
printCommand(command, ...args);
2828

2929
try {
30-
await spawnPromise(command, args, { stdio: 'inherit' });
30+
await spawnPromise(command, args, { stdio: 'inherit', shell: true });
3131
} catch (err) {
3232
throw new CLIError(`Failed to install dependencies: ${err}`);
3333
}
@@ -69,7 +69,7 @@ export async function addDeps({
6969
printCommand(command, ...args);
7070

7171
try {
72-
await spawnPromise(command, args, { stdio: 'inherit' });
72+
await spawnPromise(command, args, { stdio: 'inherit', shell: true });
7373
} catch (err) {
7474
throw new CLIError(`Failed to add dependencies: ${err}`);
7575
}

0 commit comments

Comments
 (0)