]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki/Render.pm
Added a rescan hook.
[ikiwiki.git] / IkiWiki / Render.pm
index 233d093eda602387902cfade75573ee62760a3ed..5ce802317f68d3da036aa1894708f97f92152186 100644 (file)
@@ -183,6 +183,14 @@ sub scan ($) {
 
                # Preprocess in scan-only mode.
                preprocess($page, $page, $content, 1);
+
+               run_hooks(rescan => sub {
+                       shift->(
+                               page => $page,
+                               content => $content,
+                       );
+               });
+
        }
        else {
                will_render($file, $file, 1);
@@ -232,7 +240,7 @@ sub render ($$) {
                        linkify($page, $page,
                        preprocess($page, $page,
                        filter($page, $page,
-                       readfile($srcfile), 'fullpage'))));
+                       readfile($srcfile)))));
                
                my $output=htmlpage($page);
                writefile($output, $config{destdir}, genpage($page, $content));
@@ -837,7 +845,7 @@ sub commandline_render () {
        my $content=readfile($srcfile);
        my $page=pagename($file);
        $pagesources{$page}=$file;
-       $content=filter($page, $page, $content, 'fullpage');
+       $content=filter($page, $page, $content);
        $content=preprocess($page, $page, $content);
        $content=linkify($page, $page, $content);
        $content=htmlize($page, $page, $type, $content);