2 package IkiWiki::Plugin::testpagespec;
9 hook(type => "preprocess", id => "testpagespec", call => \&preprocess);
12 sub preprocess (@) { #{{{
15 foreach my $param (qw{match pagespec}) {
16 if (! exists $params{$param}) {
17 return "[[testpagespec $param parameter is required]]";
21 add_depends($params{page}, $params{pagespec});
23 my $ret=pagespec_match($params{match}, $params{pagespec},
24 location => $params{page});
29 return "no match: $ret";