|
11 月之前 | |
---|---|---|
.. | ||
node_modules | 11 月之前 | |
LICENSE | 11 月之前 | |
README.md | 11 月之前 | |
index.js | 11 月之前 | |
package.json | 11 月之前 |
A wrapper around node-glob to make it streamy.
var gs = require('glob-stream');
var stream = gs.create('./files/**/*.coffee', { /* options */ });
stream.on('data', function(file){
// file has path, base, and cwd attrs
});
You can pass any combination of globs. One caveat is that you can not only pass a glob negation, you must give it at least one positive glob so it knows where to start. All given must match for the file to be returned.
Returns a stream for multiple globs or filters.
Returns a stream for a single glob or filter.
process.cwd()
false
false
This argument is passed directly to node-glob so check there for more options
var stream = gs.create(['./**/*.js', '!./node_modules/**/*']);
Globs are executed in order, so negations should follow positive globs. For example:
gulp.src(['!b*.js', '*.js'])
would not exclude any files, but this would
gulp.src(['*.js', '!b*.js'])
glob
wrapper with support for multiple patterns.MIT