Open bdw429s opened 7 years ago
I forgot to mention-- you can skip the fuent API and use the PathPatternMatcher
class directly to get fancy with whitelists and blacklists:
https://github.com/Ortus-Solutions/globber/blob/master/models/PathPatternMatcher.cfc
Then you could do something like:
CommandBox> cfscriptme sourcePath=./ exclude=coldbox/**,examples/*Tag.cfc
Thanks I will look into this.
So it would be super cool to allow for file globbing (especially for the CLI command) so I could say to convert folders like
/models/**.cfc
,**.cfc
, or/handlers/oneSpecificPackage/*.cfc
.I've already got a library for this that I use in CommandBox that you can just pull in as a dependency.
https://www.forgebox.io/view/globber
It's a transient with a nice fluent DSL to get directory listings for you and even handle FP-style iterations over the results.
It's also worth noting that CommandBox 3.7 will have native support for globbing parameters in commands by just setting the parameter type, but it's still in beta.