xglob
glob with mulptiple patterns.
Additionally, negation pattern can be functions or regular expressions. If truthy value returned, the negation pattern matches.
Example
⌘ tree fixtures/
fixtures/
├── a.css
├── a.js
├── d.js
├── dir
│ ├── b.css
│ ├── b.js
│ ├── c.js
│ ├── e
│ │ ├── e.css
│ │ └── e.js
│ └── f
│ ├── f.css
│ └── f.js
└── empty
glob(patterns, opts, cb)
;
files = glob.sync(patterns, opts)
console;// [ 'dir/e/', 'dir/f/' ]
negation function
var path = ;console;// [ 'dir/e/e.css', 'dir/e/e.js', 'dir/f/f.css', 'dir/f/f.js' ]
Usage
var glob = ;
glob(patterns, opts, cb)
patterns
Type: String
, Array
Passed to glob for locating files.