summaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-09-21 20:28:40 +0000
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-09-21 20:28:40 +0000
commitc7140ad90b0db2078e70b9cd3f08e1d176125191 (patch)
tree467a53b2146174d0ebd871deda873f8d0f25d06c /IkiWiki
parent75594937c4de7d98b9fdcc45403fa5de0cd32bed (diff)
* Add typography (SmartyPants) plugin by Recai.
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Plugin/typography.pm20
1 files changed, 20 insertions, 0 deletions
diff --git a/IkiWiki/Plugin/typography.pm b/IkiWiki/Plugin/typography.pm
new file mode 100644
index 000000000..d613f873b
--- /dev/null
+++ b/IkiWiki/Plugin/typography.pm
@@ -0,0 +1,20 @@
+#!/usr/bin/perl
+
+package IkiWiki::Plugin::typography;
+
+use warnings;
+use strict;
+use IkiWiki;
+
+sub import { #{{{
+ IkiWiki::hook(type => "sanitize", id => "typography", call => \&sanitize);
+} # }}}
+
+sub sanitize (@) { #{{{
+ my %params=@_;
+
+ eval q{use Text::Typography};
+ return Text::Typography::typography($params{content});
+} # }}}
+
+1