aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess <joey@kodama.kitenet.net>2008-05-08 16:08:02 -0400
committerJoey Hess <joey@kodama.kitenet.net>2008-05-08 16:08:02 -0400
commitb7950d8d01875747cfe74328358c3ff0304e4ad4 (patch)
tree17ec186804c991ecbc763299dd0a740ef784cee7
parent0168cc3c8b12cb4d1eb11889a2d9774bdd68ec59 (diff)
downloadikiwiki-b7950d8d01875747cfe74328358c3ff0304e4ad4.tar
ikiwiki-b7950d8d01875747cfe74328358c3ff0304e4ad4.tar.gz
load plugins before printing messages
This allows plugins to getopt and change what is done before an incorrect line is printed.
-rw-r--r--IkiWiki/Render.pm2
-rw-r--r--IkiWiki/Setup/Standard.pm8
2 files changed, 5 insertions, 5 deletions
diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm
index 8591731dc..eb01a4227 100644
--- a/IkiWiki/Render.pm
+++ b/IkiWiki/Render.pm
@@ -508,8 +508,6 @@ sub refresh () { #{{{
} #}}}
sub commandline_render () { #{{{
- loadplugins();
- checkconfig();
lockwiki();
loadindex();
unlockwiki();
diff --git a/IkiWiki/Setup/Standard.pm b/IkiWiki/Setup/Standard.pm
index 87db648e0..fb542be20 100644
--- a/IkiWiki/Setup/Standard.pm
+++ b/IkiWiki/Setup/Standard.pm
@@ -63,11 +63,15 @@ sub setup_standard {
$config{$c}=undef;
}
}
+
+ loadplugins();
+ checkconfig();
if ($config{render}) {
commandline_render();
}
- elsif (! $config{refresh}) {
+
+ if (! $config{refresh}) {
$config{rebuild}=1;
debug(gettext("rebuilding wiki.."));
}
@@ -75,8 +79,6 @@ sub setup_standard {
debug(gettext("refreshing wiki.."));
}
- loadplugins();
- checkconfig();
lockwiki();
loadindex();
refresh();