Maybe you could just use the usual list processing functions on the
full file list? eg. a glob like "*.html" has an obvious implementation
with filter, and isSuffixOf.
--
gwern
http://www.gwern.net
I think it's a pretty good request. I can think of a few use cases
where this might come in handy...
I will probably implement regexes instead of globs, though -- because
Hakyll already depends on regex-pcre anyway.
Cheers,
Jasper
I've just implemented [1] filename globbing. It should be fully
backward-compatible with the previous implementation. It's not on
Hackage yet because I want to do some more testing, but you can get it
from github [2] if you want.
[1]: http://github.com/jaspervdj/hakyll/commit/8bd45b
[2]: http://github.com/jaspervdj/hakyll/
Cheers,
Jasper
Cool! It seems to work fine with the basic globs I've thrown at it.
I'll let you know if I run into any problems.
I think it'd be nice if patterns acted more like sets so you could
union/intersect/subtract them. This would allow more expressive policies
like "compile all non-markdown files using copyFile". But it looks like
this wouldn't make sense with current model of Patterns/Identifiers, so
I understand if you wouldn't want to implement it.
Keep up the great work!
Sam