Когда я использую npm Запустить подачу, я получаю следующее сообщение.
PS C:\Users\Jan\Desktop\projektgruppe\Main> npm run serve
> editor@0.1.0 serve C:\Users\Jan\Desktop\projektgruppe\Main
> concurrently "nodemon -L --inspect=0.0.0.0:9001 ./server/index.js" "vue-cli-service build ./src/main.js --mode development --watch"
[0] Error occurred when executing command: nodemon -L --inspect=0.0.0.0:9001 ./server/index.js
[0] Error: spawn cmd.exe ENOENT
[0] at Process.ChildProcess._handle.onexit (internal/child_process.js:264:19)
[0] at onErrorNT (internal/child_process.js:456:16)
[0] at processTicksAndRejections (internal/process/task_queues.js:81:21)
[1] Error occurred when executing command: vue-cli-service build ./src/main.js --mode development --watch
[1] Error: spawn cmd.exe ENOENT
[1] at Process.ChildProcess._handle.onexit (internal/child_process.js:264:19)
[1] at onErrorNT (internal/child_process.js:456:16)
[1] at processTicksAndRejections (internal/process/task_queues.js:81:21)
[1] vue-cli-service build ./src/main.js --mode development --watch exited with code -4058
[0] nodemon -L --inspect=0.0.0.0:9001 ./server/index.js exited with code -4058
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! editor@0.1.0 serve: `concurrently "nodemon -L --inspect=0.0.0.0:9001 ./server/index.js" "vue-cli-service build ./src/main.js --mode development --watch"`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the editor@0.1.0 serve script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
и мой файл журнала это
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli 'C:\\Program Files\\node\\node.exe',
1 verbose cli 'C:\\Program Files\\node\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'serve'
1 verbose cli ]
2 info using npm@6.13.6
3 info using node@v12.14.1
4 verbose run-script [ 'preserve', 'serve', 'postserve' ]
5 info lifecycle editor@0.1.0~preserve: editor@0.1.0
6 info lifecycle editor@0.1.0~serve: editor@0.1.0
7 verbose lifecycle editor@0.1.0~serve: unsafe-perm in lifecycle true
8 verbose lifecycle editor@0.1.0~serve: PATH: C:\Program Files\node\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\Users\Jan\Desktop\projektgruppe\Main\node_modules\.bin;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\node\;C:\Program Files\Git\cmd;C:\Users\Jan\AppData\Local\Microsoft\WindowsApps;C:\Users\Jan\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\Jan\AppData\Roaming\npm
9 verbose lifecycle editor@0.1.0~serve: CWD: C:\Users\Jan\Desktop\projektgruppe\Main
10 silly lifecycle editor@0.1.0~serve: Args: [
10 silly lifecycle '/d /s /c',
10 silly lifecycle 'concurrently "nodemon -L --inspect=0.0.0.0:9001 ./server/index.js" "vue-cli-service build ./src/main.js --mode development --watch"'
10 silly lifecycle ]
11 silly lifecycle editor@0.1.0~serve: Returned: code: 1 signal: null
12 info lifecycle editor@0.1.0~serve: Failed to exec serve script
13 verbose stack Error: editor@0.1.0 serve: `concurrently "nodemon -L --inspect=0.0.0.0:9001 ./server/index.js" "vue-cli-service build ./src/main.js --mode development --watch"`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\node\node_modules\npm\node_modules\npm-lifecycle\index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:223:5)
13 verbose stack at ChildProcess.<anonymous> (C:\Program Files\node\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:223:5)
13 verbose stack at maybeClose (internal/child_process.js:1021:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
14 verbose pkgid editor@0.1.0
15 verbose cwd C:\Users\Jan\Desktop\projektgruppe\Main
16 verbose Windows_NT 10.0.18363
17 verbose argv "C:\\Program Files\\node\\node.exe" "C:\\Program Files\\node\\node_modules\\npm\\bin\\npm-cli.js" "run" "serve"
18 verbose node v12.14.1
19 verbose npm v6.13.6
20 error code ELIFECYCLE
21 error errno 1
22 error editor@0.1.0 serve: `concurrently "nodemon -L --inspect=0.0.0.0:9001 ./server/index.js" "vue-cli-service build ./src/main.js --mode development --watch"`
22 error Exit status 1
23 error Failed at the editor@0.1.0 serve script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
Это всегда работало, но теперь нет. Я много раз пытался удалить узлы модулей. Я много раз переустанавливал узел, но не могу найти ошибку. У меня нет проблем, когда я просто строю и запускаю. Но это не хорошо для развития.
"start": "node ./server/index.js",
"serve": "concurrently \"nodemon -L --inspect=0.0.0.0:9001 ./server/index.js\" \"vue-cli-service build ./src/main.js --mode development --watch\"",
"build": "vue-cli-service build ./src/main.js",
Буду рад любой помощи.
Спасибо