glob-extra
Utility which provides expanding of masks, dirs and files to absolute file paths.
Last updated a year ago by sipayrt .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install glob-extra 
SYNC missed versions from official npm registry.

glob-extra

Wrapper for utility fast-glob with promises support which provides expanding of masks, dirs and files to absolute file paths.

NPM version Build Status Coverage Status Dependency Status

Installation

$ npm install glob-extra

Usage

const globExtra = require('glob-extra');
const paths = ['some/path', 'other/path/*.js', 'other/deep/path/**/*.js']

// options are optional
globExtra.expandPaths(paths, options)
    .then((files) => {
        // ['/absolute/some/path/file1.js',
        // '/absolute/other/path/file2.js',
        // '/absolute/other/deep/path/dir/file3.js']
    })
    .done();

Options

  • formats {String[]} – files formats to expand; it will expand all files by default. For example:
globExtra.expandPaths(paths, {formats: ['.txt', '.js']})
    .then((files) => {
        // will expand only js and txt files
    })
    .done();

Current Tags

  • 4.0.2                                ...           latest (a year ago)

13 Versions

  • 4.0.2                                ...           a year ago
  • 4.0.1                                ...           a year ago
  • 4.0.0                                ...           2 years ago
  • 3.0.0                                ...           2 years ago
  • 2.0.0                                ...           3 years ago
  • 1.3.3                                ...           4 years ago
  • 1.3.2                                ...           4 years ago
  • 1.3.1                                ...           4 years ago
  • 1.3.0                                ...           4 years ago
  • 1.2.0                                ...           4 years ago
  • 1.1.1                                ...           4 years ago
  • 1.1.0                                ...           4 years ago
  • 1.0.0                                ...           4 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 17
Dependencies (5)
Dev Dependencies (8)

Copyright 2014 - 2016 © taobao.org |