Skip to content
/ meta-fs Public
forked from dvv/meta-fs

Higher level filesystem utilities for Node.js

License

Notifications You must be signed in to change notification settings

NHQ/meta-fs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Higher level filesystem utilities

Build Status

Usage

// import augmented 'fs' module
var Fs = require('meta-fs')

// print everything under /etc
Fs.find('/etc', {
  match_fn: function (path, stat, depth, cb) {
    console.log('FOUND', path)
    // you can stop walking by passing an error to `cb`
    cb(depth > 3 and true or nil)
  }
}, function (err) {
  console.log('DONE', err)
})


// remove /home/foo completely
Fs.remove('/home/foo', console.log)


// make nested directories
Fs.mkdir_p('/home/foo/bar/baz', console.log)


// copy source file/directory
Fs.copy('/home/foo/bar/baz', '/tmp/wow', console.log)


// make symlink
Fs.link('/etc/passwd', '/tmp/passes', console.log)

License

MIT

About

Higher level filesystem utilities for Node.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published