2 package IkiWiki::Plugin::testpagespec;
9 hook(type => "getsetup", id => "testpagespec", call => \&getsetup);
10 hook(type => "preprocess", id => "testpagespec", call => \&preprocess);
18 section => "special-purpose",
25 foreach my $param (qw{match pagespec}) {
26 if (! exists $params{$param}) {
27 error sprintf(gettext("%s parameter is required"), $param);
31 add_depends($params{page}, $params{pagespec});
33 my $ret=pagespec_match($params{match}, $params{pagespec},
34 location => $params{page});
39 return "no match: $ret";