-
-
Save zoutepopcorn/00d129df72f194a93559c79f62e2cada to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var md5 = require('md5'); | |
var dir = __dirname + "\\uploads"; | |
console.log(dir); | |
var test = "hi there"; | |
fs.readdir(dir, function(err, items) { | |
console.log(test); | |
for (var i=0; i<items.length; i++) { | |
var pad = dir + "\\" + items[i]; | |
console.log(items[i]); | |
var text = fs.readFileSync(pad,'utf8') | |
console.log (md5(text)); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment