node-watch
Advanced tools
Comparing version 0.3.4 to 0.3.5
@@ -19,9 +19,9 @@ /** | ||
Object.keys(shortcuts).forEach(function(method) { | ||
var stat = fs[method === 'sym' ? 'lstatSync' :'statSync']; | ||
ret[method] = function(fpath) { | ||
var stat = fs[method === 'sym' ? 'lstatSync' :'statSync']; | ||
if (fs.existsSync(fpath)) { | ||
try { | ||
var yes = stat(fpath)['is' + shortcuts[method]](); | ||
memo.push(fpath, method); | ||
return stat(fpath)['is' + shortcuts[method]](); | ||
} | ||
return false; | ||
return yes; | ||
} catch(e) {} | ||
} | ||
@@ -211,3 +211,3 @@ }); | ||
} | ||
// Due to the unstalbe fs.watch(), if the `fpath` is a file then | ||
// Due to the unstable fs.watch(), if the `fpath` is a file then | ||
// switch to watch its parent directory instead of watch it directly. | ||
@@ -214,0 +214,0 @@ // Once the logged filename matches it then triggers the callback function. |
{ | ||
"name": "node-watch" | ||
, "version": "0.3.4" | ||
, "description": "fs.watch() wrapper of Nodejs " | ||
, "url": "https://github.com/yuanchuan/node-watch" | ||
, "author": "yuanchuan <yuanchuan23@gmail.com> (http://yuanchuan.name)" | ||
, "main": "./lib/watch.js" | ||
, "keywords": ["nodewatch", "watch", "watchfile"] | ||
, "bugs": { | ||
"url": "https://github.com/yuanchuan/node-watch/issues" | ||
} | ||
, "repository": { | ||
"type": "git" | ||
, "url": "git://github.com/yuanchuan/node-watch.git" | ||
} | ||
"description": "fs.watch() wrapper of Nodejs ", | ||
"license": "MIT", | ||
"name": "node-watch", | ||
"repository": { | ||
"url": "git://github.com/yuanchuan/node-watch.git", | ||
"type": "git" | ||
}, | ||
"keywords": [ | ||
"fs.watch", | ||
"watch", | ||
"watchfile" | ||
], | ||
"version": "0.3.5", | ||
"bugs": { | ||
"url": "https://github.com/yuanchuan/node-watch/issues" | ||
}, | ||
"url": "https://github.com/yuanchuan/node-watch", | ||
"author": "yuanchuan <yuanchuan23@gmail.com> (http://yuanchuan.name)", | ||
"main": "./lib/watch.js", | ||
"homepage": "https://github.com/yuanchuan/node-watch#readme", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
9100