[emacs-berlin] writing about org-mode Babel in org-mode

Gary Phillips gary.phillips at rolmo.com
Sun Sep 22 17:35:56 UTC 2019


Hi All,
I'm in Berlin again for a short time and hope to see you at Wednesday's
meeting (if I have the correct date!).
If anyone is interested I would like to share about customising org-mode
export.
It's simpler than you might think.

Emacs org-mode allows you to write and evaluate source code blocks in your
org documents. It's called org-babel.
Writing about this feature in org-mode is tricky because when you export
the org document it removes the special syntax which tells org-mode about
the code. Quoting helps but you lose the code highlighting and can't
execute quoted code in the original org file. You end up duplicating code
blocks which is very bad.
I wrote a very small org-mode exporter which does the right thing for
source code blocks and doesn't require duplication or quoting. The exporter
code is tiny but it took several days to figure out what to do!
Cheers
Gary
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailb.org/pipermail/emacs-berlin/attachments/20190922/ee3d9e1a/attachment.html>


More information about the emacs-berlin mailing list