Skip to content
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

Why watchFile on Linux? #50

Closed
mishoo opened this issue Jul 17, 2013 · 3 comments
Closed

Why watchFile on Linux? #50

mishoo opened this issue Jul 17, 2013 · 3 comments

Comments

@mishoo
Copy link

mishoo commented Jul 17, 2013

I noticed that here https://github.com/paulmillr/chokidar/blob/master/src/index.coffee#L114 Chokidar decides to use fs.watchFile on Linux, and that one polls. I'm no expert on this, but I thought fs.watch is stable on Linux.. any reason to not use it?

@paulmillr
Copy link
Owner

I believe fs.watch is still unstable even though docs say otherwise.

Reported bugs were not closed: https://github.com/joyent/node/search?q=fs.watch&ref=cmdform&type=Issues

nodejs/node-v0.x-archive#3172 is a good example.

If it was as reliable as watchFile, I’d switch to it, as I like performance.

@alextreppass
Copy link
Contributor

Can the choice of using watch vs watchFile be configurable? Leaving it up to the user would mitigate #50 and #52

@paulmillr
Copy link
Owner

fixed. you can specify fs.watch now.

taratatach pushed a commit to taratatach/chokidar that referenced this issue Oct 2, 2023
taratatach pushed a commit to taratatach/chokidar that referenced this issue Oct 2, 2023
Fix var scoping on proxy function (fixes paulmillr#50)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants