make/remove (synchronous) directories recursively
Installation
Install through NPM
npm install mkdir-recursive
or
git clone git://github.com/hex7c0/mkdir-recursive.git
API
inside nodejs project
var fx = require('mkdir-recursive');
fx.mkdir('foo/bar/1', function(err) {
console.log('done');
});
mkdir(path, [mode], callback) Node
path
- String Dir pathname (default "required")[mode]
- Number Scrivi (default "0777")callback
- Function Next callback when task is complete (default "required")
mkdirSync(path, [mode]) Node
path
- String Dir pathname (default "required")[mode]
- Number Scrivi (default "0777")
rmdir(path, callback) Node
path
- String Dir pathname (default "required")callback
- Function Next callback when task is complete (default "required")
rmdirSync(path) Node
path
- String Dir pathname (default "required")
Examples
Take a look at my examples