From: Joey Hess Date: Thu, 10 Sep 2009 17:44:27 +0000 (-0400) Subject: Merge branch 'master' into cvs X-Git-Tag: 3.14159265~75 X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/commitdiff_plain/81a9b5feffa241cea901c3633323bb446d61edf3?hp=-c Merge branch 'master' into cvs --- 81a9b5feffa241cea901c3633323bb446d61edf3 diff --combined IkiWiki.pm index 453bc9f8c,187d40a3a..85d8eea68 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@@ -33,6 -33,7 +33,7 @@@ use Memoize memoize("abs2rel"); memoize("pagespec_translate"); memoize("file_pruned"); + memoize("template_file"); sub getsetup () { wikiname => { @@@ -149,6 -150,13 +150,13 @@@ safe => 0, # path rebuild => 1, }, + templatedirs => { + type => "internal", + default => [], + description => "additional directories containing template files", + safe => 0, + rebuild => 0, + }, underlaydir => { type => "string", default => "$installdir/share/ikiwiki/basewiki", @@@ -336,7 -344,7 +344,7 @@@ qr/\.x?html?$/, qr/\.ikiwiki-new$/, qr/(^|\/).svn\//, qr/.arch-ids\//, qr/{arch}\//, qr/(^|\/)_MTN\//, qr/(^|\/)_darcs\//, - qr/\.dpkg-tmp$/], + qr/(^|\/)CVS\//, qr/\.dpkg-tmp$/], description => "regexps of source files to ignore", safe => 0, rebuild => 1, @@@ -356,7 -364,7 +364,7 @@@ }, web_commit_regexp => { type => "internal", - default => qr/^web commit (by (.*?(?=: |$))|from (\d+\.\d+\.\d+\.\d+)):?(.*)/, + default => qr/^web commit (by (.*?(?=: |$))|from ([0-9a-fA-F:.]+[0-9a-fA-F])):?(.*)/, description => "regexp to parse web commits from logs", safe => 0, rebuild => 0, @@@ -1609,7 -1617,8 +1617,8 @@@ sub saveindex () sub template_file ($) { my $template=shift; - foreach my $dir ($config{templatedir}, "$installdir/share/ikiwiki/templates") { + foreach my $dir ($config{templatedir}, @{$config{templatedirs}}, + "$installdir/share/ikiwiki/templates") { return "$dir/$template" if -e "$dir/$template"; } return;