parallel
parallel copied to clipboard
Parallel `npm` commands are not running on Windows
DESKTOP-TA4UEMI+Karbonara@DESKTOP-TA4UEMI MINGW64 /c/OSPanel/home/second.investprojects.local (7758-add-frontend-pipeline-into-di)
$ parallel ::: 'npm run _site/testing:run'
parallel: Error: spawn npm run _site/testing:run ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
I think the problem is you are executing the WHOLE string as command. The example above doesn't quite make sense, it seems like it's running a single command. This tool is meant for running many. For example
parallel npm run {} ::: script1 script2 script3
Corrected syntax:
DESKTOP-TA4UEMI+Karbonara@DESKTOP-TA4UEMI MINGW64 /c/OSPanel/home/hybrids (fix(store)-types-of-direct-methods)
$ parallel npm run {} ::: karma lint
parallel: Error: spawn npm ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
Seems like the environment doesn't have NPM
DESKTOP-TA4UEMI+Karbonara@DESKTOP-TA4UEMI MINGW64 /c/OSPanel/home/first.investprojects.local (5304-add-checkbox)
$ parallel npm run {} ::: karma lint
parallel: Error: spawn npm ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
DESKTOP-TA4UEMI+Karbonara@DESKTOP-TA4UEMI MINGW64 /c/OSPanel/home/first.investprojects.local (5304-add-checkbox)
$ npm -v
10.9.2
DESKTOP-TA4UEMI+Karbonara@DESKTOP-TA4UEMI MINGW64 /c/OSPanel/home/first.investprojects.local (5304-add-checkbox)
$ node -v
v23.9.0