-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ignore node_modules and .git by default #230
Comments
This will also fix #214. |
+1 |
1 similar comment
+1 |
+1 from me - can't see any real reason why I'd ever explicitly want those file changes to trigger a restart. Plus, if it's able to be done explicitly, the minority of people who want to do that can do. |
+1 |
+1 for sure, seems much better as an opt-in |
I'd say -1 for node_modules. It doesn't change that frequently, and the times it does (npm install or npm update) you would probably want nodemon to restart (at least in the case of node_modules). Lets say I am in a project, with nodemon running, wanting to update some modules. I do The only downside I can see from nodemon watching node_modules folders is if you npm install and it restarts. |
@keithamus the justification for ignoring node_modules is that on linux, when there's a large number of files (over a few thousand) is that nodemon throws an exception. The fix is to up the file watch limit, but it's a hack fix. Equally, I'm in the same boat, I want my app to restart when I change the node_modules, but the way I usually do it (i.e. my workflow) is (in the same terminal), nodemon is stopped, I |
Not sure how complicated it would be - but perhaps the perfect compromise would be to ignore all files inside node_modules that ARENT package.json? What way it keeps the ulimit down while keeping the functionality there. |
@keithamus maybe all the node_module directories in the node_modules directories is what needs to be ignored. |
@remy true that, double true. |
Okay, that seems to make a good compromise, by default I'm ignoring: .git and node_modules/**/node_modules. Got it working on the #200 offline branch right now. |
excellent compromise @remy and @keithamus |
👍 never watched the node_modules anyway |
I'm proposing this for the #200 branch which will make nodemon 1.0.0 - hopefully very soon.
I'd love a +1 or -1 (and why) from people.
Currently going to proceed with this.
If you want to include node_modules, you'd include it explicitly in the watch params, probably something like this:
The text was updated successfully, but these errors were encountered: