请教,windows上,关闭cmd窗口,报错
发布于 8 年前 作者 einsqing 5115 次浏览 来自 问答

VirtualBox_win7_26_12_2016_14_13_17.png VirtualBox_win7_26_12_2016_14_13_26.png

报错具体如下

0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli   'start' ]
2 info using npm@3.10.10
3 info using node@v7.3.0
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle koahubjs-demo@0.0.8~prestart: koahubjs-demo@0.0.8
6 silly lifecycle koahubjs-demo@0.0.8~prestart: no script for prestart, continuing
7 info lifecycle koahubjs-demo@0.0.8~start: koahubjs-demo@0.0.8
8 verbose lifecycle koahubjs-demo@0.0.8~start: unsafe-perm in lifecycle true
9 verbose lifecycle koahubjs-demo@0.0.8~start: PATH: C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\Users\heqing\Desktop\wemall\node_modules\.bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\nodejs\;C:\Program Files\Git\cmd;C:\Users\heqing\AppData\Roaming\npm
10 verbose lifecycle koahubjs-demo@0.0.8~start: CWD: C:\Users\heqing\Desktop\wemall
11 silly lifecycle koahubjs-demo@0.0.8~start: Args: [ '/d /s /c', 'koahub start app/index.js' ]
12 verbose stack Error: kill ENOSYS
12 verbose stack     at exports._errnoException (util.js:1022:11)
12 verbose stack     at process.kill (internal/process.js:173:13)
12 verbose stack     at process.listener (C:\Program Files\nodejs\node_modules\npm\node_modules\npmlog\node_modules\gauge\node_modules\signal-exit\index.js:86:15)
12 verbose stack     at emitNone (events.js:91:20)
12 verbose stack     at process.emit (events.js:185:7)
12 verbose stack     at processEmit (C:\Program Files\nodejs\node_modules\npm\node_modules\npmlog\node_modules\gauge\node_modules\signal-exit\index.js:146:32)
12 verbose stack     at processEmit (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-registry-client\node_modules\npmlog\node_modules\gauge\node_modules\signal-exit\index.js:146:32)
12 verbose stack     at Signal.wrap.onsignal (internal/process.js:200:44)
13 verbose cwd C:\Users\heqing\Desktop\wemall
14 error Windows_NT 6.1.7600
15 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
16 error node v7.3.0
17 error npm  v3.10.10
18 error code ENOSYS
19 error errno ENOSYS
20 error syscall kill
21 error kill ENOSYS
22 error If you need help, you may report this error at:
22 error     <https://github.com/npm/npm/issues>
23 verbose exit [ 1, true ]

请教如何解决

8 回复

关闭 cmd 窗口报错是什么意思?关闭前都是正常的么?

对于win下的问题,坛子的大多数人都会让你自求多福的…别问我为什么…

@xcatliu 就是点击下cmd窗口的关闭按钮,然后报了一堆错

@einsqing 点 cmd 之前可以 Ctrl+C 关闭程序呢?

另外,Windows 下建议使用 Git Bash 替代 cmd,好用多了。

@xcatliu 这样是正常的

@xcatliu 进一步测试,是因为使用了npm start引起的

@xcatliu VirtualBox_win7_26_12_2016_16_11_38.png VirtualBox_win7_26_12_2016_16_11_50.png

直接node http.js启动,关闭cmd窗口不会报错。 如果npm start启动,关闭cmd窗口报错。

回到顶部