0.1.1 • Published 12 years ago

directory-tree-watcher v0.1.1

Weekly downloads
21
License
-
Repository
github
Last release
12 years ago

directory-tree-watcher

Extend the functionality of fs.watch(filename, [options], listener) to subdirectories.

Example usage:

var watch = require("directory-tree-watcher");

watch(".", function(event, file) {
    console.log("watcher:", event, file);
});

watch(directory, [options,] listener, callback)

Watches a directory and all sub-directories. options are the same as for fs.watch(filename, [options], listener). The listener is also passed to fs.watch(filename, [options], listener). The callback is passed two parameters. The first parameter is an error (if any). The second parameter of the callback a Watcher object, which responds to a close() method, which closes the watcher.

Testing

Install jake: npm install -g jake

Note that Jake is a system-level tool, and wants to be installed globally.

To execute tests execute: jake test

License

MIT License. View it at LICENSE file.

0.1.1

12 years ago

0.1.0

12 years ago

0.0.5

12 years ago

0.0.4

12 years ago

0.0.2

12 years ago

0.0.1

12 years ago