]> sipb.mit.edu Git - ikiwiki.git/blobdiff - ikiwiki
allow hooks to add options even to --setup
[ikiwiki.git] / ikiwiki
diff --git a/ikiwiki b/ikiwiki
index cdb2042e170a3f8a89373b76429a2a0f93c784b9..58f6af4ba521b460377f94a74742d3f424862ee4 100755 (executable)
--- a/ikiwiki
+++ b/ikiwiki
@@ -15,12 +15,14 @@ sub getconfig () { #{{{
        if (! exists $ENV{WRAPPED_OPTIONS}) {
                %config=defaultconfig();
                eval q{use Getopt::Long};
+               Getopt::Long::Configure('pass_through');
                GetOptions(
                        "setup|s=s" => \$config{setup},
                        "wikiname=s" => \$config{wikiname},
                        "verbose|v!" => \$config{verbose},
                        "rebuild!" => \$config{rebuild},
                        "refresh!" => \$config{refresh},
+                       "wrappers!" => \$config{wrappers},
                        "getctime" => \$config{getctime},
                        "wrappermode=i" => \$config{wrappermode},
                        "rcs=s" => \$config{rcs},
@@ -66,6 +68,7 @@ sub getconfig () { #{{{
                ) || usage();
 
                if (! $config{setup}) {
+                       loadplugins();
                        usage() unless @ARGV == 2;
                        $config{srcdir} = possibly_foolish_untaint(shift @ARGV);
                        $config{destdir} = possibly_foolish_untaint(shift @ARGV);
@@ -79,6 +82,7 @@ sub getconfig () { #{{{
                if ($@) {
                        error("WRAPPED_OPTIONS: $@");
                }
+               loadplugins();
                checkconfig();
        }
 } #}}}