Skip to content

Instantly share code, notes, and snippets.

@75lb
Last active August 29, 2015 14:23
Show Gist options
  • Save 75lb/6b944fcd75836e8de2d6 to your computer and use it in GitHub Desktop.
Save 75lb/6b944fcd75836e8de2d6 to your computer and use it in GitHub Desktop.
renamer test
var fs = require("fs");
var path = require("path");
var dirs = [ "one", "one/two", "one/two/three" ];
var files = [ "file1.txt", "file2.txt", "file3.txt" ];
dirs.forEach(function(dir){
fs.mkdirSync(dir);
files.forEach(function(file){
fs.writeFileSync(path.join(dir, file));
});
});
{
"name": "renamer-test",
"version": "1.0.0",
"dependencies": {
"renamer": "^0.5.5"
},
"scripts": {
"test": "renamer -f .txt -r .yeah -d one/**"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment