This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When using 'npm scripts' and running the angular-seed project "CTRL-C" is given as output to stop the server. This sequence seems to be filtered from the "Run" window, so stopping does not work. Using the red stop button works, though.
@jhavlin: Jardo, could you please advice? Thanks.
Output Window is not a terminal emulator. It just displays redirected output of some process, but it does not control the process. Who gives "CTRL-C" as output, the user or the script running in output window? Can you please provide steps to reproduce? Or sample project? I'm sorry, I'm not very familiar with HTML projects, so maybe I don't understand the problem correctly. Thank you.
Created attachment 151869 [details] showing ctrl-c This is the output from: - Rightclick on project - npm scripts -> start (effectively calling '/usr/bin/npm run-script start') Does this help to get the context?
@reporter: Please, provide exact steps to reproduce, step by step. E.g.: - start NetBeans - run this - click there - press Enter - type XYZ - ... -> expected: ... -> actual: ... Simply reopen this issue, thanks.
Hope this helps: Start netbeans Create a new html5/javascript project Site Template: Download online template > angularjs seed right click project > npm scripts > start Last lines: Starting up http-server, serving ./ on port: 8000 Hit CTRL-C to stop the server I assume "ctrl-c" is caught as 'copy' shortcut.
Thank you very much. The problem is that the process behaves as if it was started in terminal, which sends sigkill when Ctrl+C is pressed, but Output Window is not a terminal, it just shows redirected output of the process. We can mimic this behavior by having Ctrl+C shortcut for the stop button (if no text is selected, maybe with showing a confirmation dialog "Really stop process?"). Reassigning to platform/Output Window.
Sounds good to me. Thanks.
http://hg.netbeans.org/core-main/rev/6777b7f1144e Fixed. We may also consider starting the npm script in terminal emulator, but it would require larger changes in module javascript.nodejs. Thank you for help.
Integrated into 'main-silver', will be available in build *201510280002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/6777b7f1144e User: Jaroslav Havlin <jhavlin@netbeans.org> Log: #250245: CTRL+C in Output Window invokes Stop action