From 5db8b5c5a6bcd42f48f27840b49882cedb89386a Mon Sep 17 00:00:00 2001 From: David Bremner Date: Sun, 31 Aug 2008 22:05:26 -0300 Subject: [PATCH] initial htmlize hook --- IkiWiki/Plugin/mailbox.pm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/IkiWiki/Plugin/mailbox.pm b/IkiWiki/Plugin/mailbox.pm index 84648e402..e619eb35f 100644 --- a/IkiWiki/Plugin/mailbox.pm +++ b/IkiWiki/Plugin/mailbox.pm @@ -28,6 +28,7 @@ sub import { #{{{ hook(type => "preprocess", id => "mailbox", call => \&preprocess); hook(type => "scan", id => "mailbox", call => \&scan); hook(type => "pagetemplate", id=>"mailbox", call => \&pagetemplate); + hook(type => "htmlize",id=>"mbox",call => \&mbox_htmlize); IkiWiki::loadplugin("filecheck"); } # }}} @@ -59,6 +60,12 @@ sub preprocess (@) { #{{{ } # }}} +sub mbox_htmlize(@){ + my %params=@_; + + my $path=$config{srcdir} . '/' . $params{page}.".mbox"; + return format_mailbox(path=>$path,type=>'Mbox',destpage=>$params{page}); +} ### The guts of the plugin ### parameters -- 2.39.5