Poll for changes#14
Conversation
Use polling to monitor for changes. Omitting the interval will default to 100ms. This option is useful if you're watching an NFS volume.
|
This PR fixes an issue we are having on windows machines. Any update on if/when this will be merged? |
| opts.usePolling = true; | ||
| opts.interval = argv.poll !== true | ||
| ? argv.poll | ||
| : undefined; |
There was a problem hiding this comment.
interval should be Number in the chokidar/lib/nodefs-handler.js#150. How about to update this part to the following?
if (typeof argv.poll === 'number') {
opts.usePolling = true;
opts.interval = argv.poll;
}There was a problem hiding this comment.
@watilde Should be:
if (argv.poll) {
opts.usePolling = true;
}
if (typeof argv.poll === 'number') {
opts.interval = argv.poll;
}
So that:
Omitting the interval will default to 100ms.
See https://github.com/paulmillr/chokidar#performance.
|
Hello Benjamin! Thanks for the nice feature patch! It will be LGTM immediately when you update the code on the point I left a comment and add a test code :) // and thanks for letting me know this! @danhayden |
|
@B3njamin ping? |
|
Hey unfortunately 😢 I don't have time to fix the above or write any tests. Is someone else able to do this.
|
|
I can fix the code, just not sure how to go about writing tests. @watilde What did you have in mind for tests? |
|
Changes made at: https://github.com/RyanZim/postcss-cli/tree/poll. Need to write tests yet. |
|
This is shipped as 59e6621. Thank you so much putting this together! |
Use polling to monitor for changes. Omitting the interval will default
to 100ms. This option is useful if you're watching an NFS volume. Fixes #13