Add OpenCL link to GPGPU post.
[blog.git] / posts / mdwn_itex.mdwn_itex
1 [[!template id=gitrepo repo=ikiwiki]]
2
3 In my [[last post|MathML]] I plugged Jason Blevins' [mdwn_itex
4 plugin][plugin].  It turns out that it was harder than I'd expected to
5 get the plugin working with ikiwiki, so I'm recording the steps I took
6 here in case other ikiwiki users find this useful.
7
8 * Install [itex2MML][]
9 * [Install][install_plugin] my updated [[mdwn_itex.pm|mdwn_itex.pm]]
10   plugin ([[mdwn_itex.patch|mdwn_itex.patch]] against Jason's
11   version).
12 * Patch your ikiwiki [templates][] to use a `DOCTYPE` supporting
13   MathML ([[mdwn_itex-templates.patch|mdwn_itex-templates.patch]]).
14 * Add config options along the lines of:
15
16         # plugins to add to the default configuration
17         add_plugins => [qw{ ... mdwn_itex ...}],
18         # plugins to disable
19         disable_plugins => [qw{... htmlscrubber htmltidy ...}],
20
21         # location of template files
22         templatedir => '/path/to/patched/templates',
23
24         # mdwn_itex plugin
25         # path to the itex2MML binary
26         itex2mml => '/usr/local/bin/itex2MML',
27         # autonumber display equations?
28         itex_num_equations => 1,
29
30 * Create new files with the `.mdwn_itex` extension, and start
31   including [itex][]:
32
33   Euler's identity
34
35   \[ e^{i \pi} + 1 = 0 \]
36
37   has lots of fun constants: $e$, $i$, $\pi$,
38   $1$, and $0$.
39
40 Which will render as
41
42 Euler's identity
43
44 \[ e^{i \pi} + 1 = 0 \]
45
46 has lots of fun constants: $e$, $i$, $\pi$, $1$, and $0$.
47
48 The `htmlscrubber` and `htmltidy` plugins must be disabled because
49 otherwise they [strip][scrubber_strip] [out][tidy_strip] the MathML
50 markup.
51
52 Update: current versions of my patched files can be found in my
53 ikiwiki git branch.
54
55 [plugin]: http://jblevins.org/git/ikiwiki/plugins.git/plain/mdwn_itex.pm
56 [itex2MML]: http://golem.ph.utexas.edu/~distler/blog/itex2MML.html
57 [install_plugin]: http://ikiwiki.info/plugins/install/
58 [templates]: http://ikiwiki.info/templates/
59 [scrubber_strip]: http://ikiwiki.info/todo/svg/
60 [tidy_strip]: http://lists.w3.org/Archives/Public/html-tidy/2006JanMar/0052.html
61 [itex]: http://golem.ph.utexas.edu/~distler/blog/itex2MMLcommands.html
62
63 [[!tag tags/blogging]]