Open yocontra opened 10 years ago
glob(['./**/*.js', '!./node_modules/**/*.js']).pipe(log()) // glob all js files except vendor
Right now I have my own glob-stream module I'm going to implement this filter into but I will try to make some time to PR the feature into this lib as well so I can eventually switch to it.
okay, looking forward to your pull request.
i want this feature for the same use case, but i still need to wrap my head around what the code is doing... :smiley:
Would it be possible to rewrite this to use micromatch, or is that simply not possible due to what the code does (which I also have a hard time wrapping my head around 😄).
Just to chime in, I would like to use this for pull-vinyl, I suspect @joakim had same idea. :p
You read my mind :) I'm working on a local fork of your (otherwise great) module right now actually, using @contra's glob-stream + stream-to-pull-stream
instead of pull-glob
. It works, but it feels dirty to convert between node stream and pull stream, I'd prefer a 100% pull stream solution.
@joakim it would be very easy to have pull-glob support multiple globs with pull-cat
! cat([glob(glob1), glob(glob2)])
etc. Maybe if glob is passed an array then it could just call to cat
?
can you give an example of what the syntax would look like?
I'd be happy to take a pull request for this. At least making a pull-request with tests will make this much more likely to happen.