summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCasey Robinson <casey@rampantmonkey.com>2018-10-22 19:49:02 -0400
committerCasey Robinson <casey@rampantmonkey.com>2018-10-22 19:49:02 -0400
commit384446ee1942b5341c29f2bd602ad5b03d6fdd04 (patch)
tree107c6849671c76675849df38e5aa0a5137a7db86
parentfacd82b7be796b04b1cf0f148e856dfb3e9de077 (diff)
downloadrampantmonkey-384446ee1942b5341c29f2bd602ad5b03d6fdd04.tar.gz
rampantmonkey-384446ee1942b5341c29f2bd602ad5b03d6fdd04.tar.bz2
rampantmonkey-384446ee1942b5341c29f2bd602ad5b03d6fdd04.zip
ascii diagrams with ditaa in org-mode
-rw-r--r--emacsos/emacsos-org.org16
1 files changed, 16 insertions, 0 deletions
diff --git a/emacsos/emacsos-org.org b/emacsos/emacsos-org.org
index fe36be8..50c00a9 100644
--- a/emacsos/emacsos-org.org
+++ b/emacsos/emacsos-org.org
@@ -93,3 +93,19 @@ Presentations. Sometimes it is helpful to use emacs to present slides rather tha
(org-remove-inline-images)
(org-present-show-cursor)))))
#+END_SRC
+
+Diagrams. I like using ASCII art to define diagrams and ditaa is a fantastic tool for rendering these diagrams.
+#+BEGIN_SRC emacs-lisp :tangle yes
+(org-babel-do-load-languages
+ 'org-babel-load-languages
+ '((ditaa . t)))
+
+(setq org-ditaa-jar-path "/usr/share/java/ditaa/ditaa-0.11.jar")
+
+(add-hook 'org-babel-after-execute-hook 'org-redisplay-inline-images)
+#+END_SRC
+
+Export as HTML
+#+BEGIN_SRC emacs-lisp :tangle yes
+(use-package htmlize :ensure t)
+#+END_SRC