Roland Mas wrote: > As discussed on IRC, here's a patch allowing you to restrict the > elements inlined by [[inline]]'s globbing according to date. New > parameters are year, month and day, and you need to have a year if you > use a month (ditto for month and day).
Thanks for the patch. I was thinking about this and it seems that there will be some scalability issues with doing things this way on large blogs with lots of history. Say you're using monthly archiving and have 5 years worth of blogs, so you have 60 archive pages. Any time *any* page in the blog changes, _all_ of these pages will need to be updated. Of course most of them won't really change, but they all depend on "blog/*", and so ikiwiki will go on and build them all. Of course, this can be ammelorated by using yearly indexes. However, I thought of an approach that avoids this. If the globlist format was expanded so it could be used to specify date ranges for patching pages, then ikiwiki would actually know that adding a new page to a blog doesn't require updating an archive page for 5 years ago. It's also probably got other applications possible from doing it in that more generic way. The immediate issue with implementing it is that there needs to be a way to match all pages that are in blog/* AND are less than date X AND are greater than date Y. But globlist syntax is currently limited to ORed conditions. Enrico had talked about implementing full boolean support earlier via a grammar, I've been thinking about implementing it as a microlanguage that ikiwiki compiles down to perl and executes. Either way, solving that that would be a prerequisite for doing date matching that way. Anyway, I don't have problems with the patch as it stands, and will probably apply it, unless I can code up a microlanguage really quickly. :-) -- see shy jo
signature.asc
Description: Digital signature

