watch-project

0.0.7 • Public • Published

Installation

npm install watch-project

Usage

watch = require("watch-project");
 
watch("dir", {stable: true}, function(e){
    switch (e.type){
        case "change":
        case "create":
        case "mkdir":
        case "delete":
        case "rmdir":
        case "mvfile":
        case "mvdir":
            console.log("file path: " + e.filename);
            console.log("[optional] origin MD5: " + e.oid);
            console.log("[optional] MD5 now: " + e.nid);
            console.log("[optional] origin file path: " + e.oname);
            break;
    }
})
 

change log

  1. 0.0.2 add stable mode (using "chokidar") for supporting old version of nodejs(0.8) and OSX(10.7)

Readme

Keywords

none

Package Sidebar

Install

npm i watch-project

Weekly Downloads

0

Version

0.0.7

License

BSD

Last publish

Collaborators

  • wangyu0248