[pmwiki-users] random musings
Joachim Durchholz
jo at durchholz.org
Sat Dec 17 01:44:58 CST 2005
Patrick R. Michaud schrieb:
> One option is to just allow wildcards directly on "group" and "name"
> values in conditionals, so that
>
> (:if group PmWiki* :) # any group begining with "PmWiki"
> (:pagelist group=PmWiki* :) # all pages in groups starting with "PmWiki"
> (:if name A*:) # any page starting with "A"
>
> But how to match both group and name simultaneously? For consistency
> with other markups, do we just use "fullname"? (Somehow I think it's
> a big ugly.)
>
> (:if fullname PmWiki.A* :) # pages starting with "A" in the PmWiki group
> (:pagelist fullname=2005.Blog* :) # "Blog*" pages in the 2005 group
>
> Hmm, I guess "fullname" isn't so bad.
How about making the left "fullname" side of the comparison a series of
PmWiki variables and delimiters?
This would open up the possibility to compare more than just the group
name; one could do things like
(:if group.user PmWiki.admin :)
I'm not sure what characters should
(Now what's really missing is a way to OR and negate conditions... but I
haven't followed conditional markup lately, it may be already there.)
> Lists of wildcards will also be allowed
>
> (:pagelist fullname=2005.Blog*,2006.Blog*:)
>
> as well as negations
>
> (:pagelist fullname=-*.HomePage,-*.RecentChanges:)
... oops, already catered for :-)
Quite expressive, though not full boolean expressions. Hopefully that's
enough anyway.
> 3. Pagelist refactoring
> Pagelist has evolved *very* nicely from where I started over a year
> ago, but the code is becoming pretty crufty in the interest of
> preserving backwards compatibility. It may be time to do a major
> refactoring for pagelist (we are in beta, after all), and provide
> the current pagelist code as an optional module or recipe for
> sites with custom pagelist settings and need time to migrate
> those into the new framework. However, custom FPL formatting
> functions would continue to work in the new version w/o modification
> -- the refactoring would affect only those people who have
> customizations that rely heavily on the existence of current
> variables and their values.
No serious problems with that.
As long as there's a viable migration path :-)
Regards,
Jo
More information about the pmwiki-users
mailing list