-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Labels
Description
Microsoft Windows [Version 10.0.17134.112]
I am trying to use chokidar, a popular nodejs file system watcher library.
Whenever I use chokidar to listen for file system changes, I can no longer rename folders that lie within the folder being watched.
npm install chokidarmkdir testecho hello > test/test.txt- create
repro.js:
var fs = require('fs');
var chokidar = require('chokidar');
// Watch current directory and ignore the node_modules folder
chokidar.watch('.', {ignored: /node_modules/}).on('all', (event, path) => {
console.log(event, path);
});
// After sufficient time, attempt to rename the test folder
// Note: this is also reproducible using `mv` on the command line
setTimeout(function() {
fs.rename('test', 'test2', function(err) {
if (err) {
console.log(err);
} else {
console.log('rename ok');
}
});
}, 1000);I don't think it is terribly important (other colleagues are able to reproduce with other node versions), but I am using nodejs v8.11.3
tuomastanner, jorgeorpinel and DevSchmidtchen

