X-Git-Url: https://sipb.mit.edu/gitweb.cgi/ikiwiki.git/blobdiff_plain/702b8721d360ca132ff5c8f43d332757694b98da..d564e3252a549c5de9359eddedffb8fe16b0cf45:/IkiWiki.pm diff --git a/IkiWiki.pm b/IkiWiki.pm index 3803bb917..703b596a8 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -30,7 +30,7 @@ sub defaultconfig () { #{{{ wiki_file_prune_regexp => qr{((^|/).svn/|\.\.|^\.|\/\.|\.x?html?$|\.rss$|\.atom$|.arch-ids/|{arch}/)}, wiki_link_regexp => qr/\[\[(?:([^\]\|]+)\|)?([^\s\]]+)\]\]/, wiki_file_regexp => qr/(^[-[:alnum:]_.:\/+]+$)/, - web_commit_regexp => qr/^web commit (by (.*?(?=: )|[^:]+)|from (\d+\.\d+\.\d+\.\d+)):?(.*)/, + web_commit_regexp => qr/^web commit (by (.*?(?=: |$))|from (\d+\.\d+\.\d+\.\d+)):?(.*)/, verbose => 0, syslog => 0, wikiname => "wiki", @@ -62,7 +62,7 @@ sub defaultconfig () { #{{{ setup => undef, adminuser => undef, adminemail => undef, - plugin => [qw{mdwn inline htmlscrubber}], + plugin => [qw{mdwn inline htmlscrubber passwordauth}], timeformat => '%c', locale => undef, sslcookie => 0, @@ -663,7 +663,15 @@ sub run_hooks ($$) { # {{{ my $sub=shift; if (exists $hooks{$type}) { + my @deferred; foreach my $id (keys %{$hooks{$type}}) { + if ($hooks{$type}{$id}{last}) { + push @deferred, $id; + next; + } + $sub->($hooks{$type}{$id}{call}); + } + foreach my $id (@deferred) { $sub->($hooks{$type}{$id}{call}); } }