Skip to content

'add' and 'unlink' events not triggering with folders #11

Description

@HRK44

Ubuntu 18.04.1

The add event is not triggering on folder creating, same for unlink.

    let rootWatcher = new INotifyWait(dir, {
        recursive: true
    });

    rootWatcher.on('ready', () => console.log('watching now...'));
    rootWatcher.on('add', (filename, stats) => console.log('new file created : ' + filename));
    rootWatcher.on('unknown', filename => console.log('unknown event...'));
    rootWatcher.on('unlink', filename => {
        console.log('deleted file : ' + filename);
        // rootWatcher.close();
    });

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions