Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Nodeclipse + nodemon error

When I try to run an express app in nodeclipse, it gives me the error,

23 Jan 11:58:04 - [33m[nodemon] v1.0.13[39m

23 Jan 11:58:04 - [33m[nodemon] to restart at any time, enter rs[39m

23 Jan 11:58:04 - [33m[nodemon] watching: .[39m

23 Jan 11:58:04 - [32m[nodemon] starting node /home/rdteam/workspace/NedvedNodeExpressTest/app.js[39m

[31m[nodemon] unable to run executable: "node"[39m

However, when I run from command line that node /home/rdteam/workspace/NedvedNodeExpressTest/app.js or nodemon /home/rdteam/workspace/NedvedNodeExpressTest/app.js

both work without problem.

Pls help.

Regards Hammer

like image 712
Hammer Avatar asked May 18 '26 22:05

Hammer


2 Answers

In my case (running os x) I quick solved it setting the full path in :

/usr/local/lib/node_modules/nodemon/lib/monitor/run.js

function run(options) {
    var cmd = config.command.raw;

    //Added line
    cmd.executable = '/usr/local/bin/node';
like image 89
rubenruizdegauna Avatar answered May 20 '26 21:05

rubenruizdegauna


I was able to solve this problem by using the forever module, and configuring Nodeclipse's 'Node monitor path' to point to forever (*../npm/node_modules/forever/bin/forever*)

  • npm install forever
  • Open Eclipse -> Preferences -> Nodeclipse
  • Set the 'Node monitor path' to your installation of forever, and you're done.

I ran headlong into this problem whilst setting up Nodeclipse, and getting my node programs to work on Eclipse Kepler running on Mac OS X 10.8.5 (Mountain Lion)

like image 25
stuxnetting Avatar answered May 20 '26 22:05

stuxnetting



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!