diff --git a/modules/lang/markdown/autoload.el b/modules/lang/markdown/autoload.el index 7fcfcd97a..073d4dedb 100644 --- a/modules/lang/markdown/autoload.el +++ b/modules/lang/markdown/autoload.el @@ -75,6 +75,16 @@ Returns its exit code." "pandoc" "-f" "markdown" "-t" "html" "--standalone" "--mathjax" "--highlight-style=pygments"))) +;;;###autoload +(defun +markdown-compile-multimarkdown (beg end output-buffer) + "Compiles markdown with the multimarkdown program, if available. Returns its +exit code." + (when (executable-find "multimarkdown") + (call-process-region beg end + shell-file-name nil output-buffer nil + shell-command-switch + "multimarkdown"))) + ;;;###autoload (defun +markdown-compile-markdown (beg end output-buffer) "Compiles markdown using the Markdown.pl script (or markdown executable), if diff --git a/modules/lang/markdown/config.el b/modules/lang/markdown/config.el index 8db2958e0..97593f2d3 100644 --- a/modules/lang/markdown/config.el +++ b/modules/lang/markdown/config.el @@ -3,7 +3,8 @@ (defvar +markdown-compile-functions '(+markdown-compile-marked +markdown-compile-pandoc - +markdown-compile-markdown) + +markdown-compile-markdown + +markdown-compile-multimarkdown) "A list of commands to try when attempting to build a markdown file with `markdown-open' or `markdown-preview', stopping at the first one to return non-nil.