remy / nodemon

Monitor for any changes in your node.js application and automatically restart the server - perfect for development
http://nodemon.io/
MIT License
26.28k stars 1.73k forks source link

Running required nodemon multiple times #286

Closed remy closed 7 years ago

remy commented 10 years ago

Will fix this https://github.com/JacksonGariety/gulp-nodemon/issues/6

Currently if you require nodemon, it's a static, so you can require multiple times (or rather - it makes no difference).

I'm not sure what to do right now, whether nodemon should return a new instance (which is potentially a lot of work...possibly) or whether nodemon internally tracks multiple monitors (which is potentially messy).

Would love any community input, ideas and help to code this up if possible.

darzu commented 10 years ago

I'm running into this issue myself. (I'm trying to run multiple instances via Gulp.) I think returning new instances makes the most sense although I can see how that would be a big refactor and definitely API breaking. Still, I think that'd be the right thing to do. I'm working on getting familiar with the codebase now to see how much work it'd be.

let4be commented 9 years ago

a whole year passed and issue is not resolved ^^ The same problem, any workaround?

darzu commented 9 years ago

For my project, I think we ended up using https://github.com/substack/watchify or the built-in Gulp watch features.

ratson commented 8 years ago

@remy Is there any plan to add this feature?

remy commented 7 years ago

No, not without a PR.

simison commented 7 years ago

We've been using concurrently together with gulp-nodemon: https://github.com/Trustroots/trustroots/blob/master/package.json#L22

mjy78 commented 7 years ago

If you're using gulp to launch nodemon you can use node-multi-process to launch multiple instances. See example here https://github.com/JacksonGariety/gulp-nodemon/issues/6#issuecomment-330788506