JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 9
  • Score
    100M100P100Q48767F
  • License MIT

File system and globbing utilities

Package Exports

  • micro-fs

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (micro-fs) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

micro-fs

File system and globbing utilities

NPM version NPM downloads Build Status Coverage Status Dependency Status Greenkeeper badge


Install

$ npm install micro-fs -S

Usage

const mfs = require('micro-fs');

mfs.copy('src/**/*.js', 'lib').then(() => {
  console.log('copy done.');
});

mfs.move('src/**/*.js', 'lib').then(() => {
  console.log('move done.');
});

mfs.delete('dist/**').then(() => {
  console.log('delete done.');
});

mfs.zip('src/**/*.js', 'source.zip').then(() => {
  console.log('archive done.');
});

mfs.glob('src/**/*.js', options).then(files => {
  console.log(files);
  /**
   * [{ cwd, base, path }]
   */
});

API

  • mfs.copy(src, dest, options) => Promise
  • mfs.move(src, dest, options) => Promise
  • mfs.zip(src, dest, options) => Promise
  • mfs.glob(src, options) => Promise
  • mfs.delete(src, options) => Promise

src is globs and options are documented in glob-stream.

Report a issue

License

micro-fs is available under the terms of the MIT License.