]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki.pm
typo
[ikiwiki.git] / IkiWiki.pm
index 27fa4ca17dd3a17fa6768acb5e496758a3eb55a7..701f7137dd78483215637e205bbde0b720ea0387 100644 (file)
@@ -441,6 +441,13 @@ sub getsetup () {
                safe => 0,
                rebuild => 0,
        },
+       wrapper_background_command => {
+               type => "internal",
+               default => '',
+               description => "background shell command to run",
+               safe => 0,
+               rebuild => 0,
+       },
        gettime => {
                type => "internal",
                description => "running in gettime mode",
@@ -592,10 +599,11 @@ sub loadplugins () {
        return 1;
 }
 
-sub loadplugin ($) {
+sub loadplugin ($;$) {
        my $plugin=shift;
+       my $force=shift;
 
-       return if grep { $_ eq $plugin} @{$config{disable_plugins}};
+       return if ! $force && grep { $_ eq $plugin} @{$config{disable_plugins}};
 
        foreach my $dir (defined $config{libdir} ? possibly_foolish_untaint($config{libdir}) : undef,
                         "$installdir/lib/ikiwiki") {
@@ -1739,11 +1747,20 @@ sub template ($;@) {
 sub misctemplate ($$;@) {
        my $title=shift;
        my $content=shift;
+       my %params=@_;
        
        my $template=template("page.tmpl");
 
+       my $page="";
+       if (exists $params{page}) {
+               $page=delete $params{page};
+       }
        run_hooks(pagetemplate => sub {
-               shift->(page => "", destpage => "", template => $template);
+               shift->(
+                       page => $page,
+                       destpage => $page,
+                       template => $template,
+               );
        });
        templateactions($template, "");
 
@@ -1754,7 +1771,7 @@ sub misctemplate ($$;@) {
                content => $content,
                baseurl => baseurl(),
                html5 => $config{html5},
-               @_,
+               %params,
        );
        
        return $template->output;
@@ -1830,11 +1847,11 @@ sub rcs_prepedit ($) {
        $hooks{rcs}{rcs_prepedit}{call}->(@_);
 }
 
-sub rcs_commit ($$$;$$) {
+sub rcs_commit (@) {
        $hooks{rcs}{rcs_commit}{call}->(@_);
 }
 
-sub rcs_commit_staged ($$$) {
+sub rcs_commit_staged (@) {
        $hooks{rcs}{rcs_commit_staged}{call}->(@_);
 }