Closed TimMensch closed 8 years ago
Because there was an outstanding bug asking for the ability to check file globs, I thought I'd go ahead and add globs to the "extra" feature.
Thanks for the contribution @TimMensch. I'll pull this in and then release after adding tests to cover the new functionality.
I added an "extra" parameter to options that will take a string or an array of strings that each refer to a filename. These files are configuration files related to the stream we're processing, but they are not themselves part of the stream; any change in the configuration files will cause all of the files to be rebuilt.
You can, for instance, add './gulpfile.js' to extra for a particular task, causing all files in that task to be rebuilt when gulpfile.js is touched. Alternately, if your transpiler configuration file is changed, gulp-newer can transpile all source files (if you make the transpiler configuration file an "extra" dependency).
I tested both 1-to-1 and 1-to-many cases, and I made sure that the current tests all pass. I didn't add new tests for this; I'm not really familiar with mocha, and I need to get back to my main project. Hoping this isn't a deal killer.