summary refs log tree commit diff stats
path: root/tag-emacs/emacs.d
diff options
context:
space:
mode:
authorAlan Pearce2014-07-12 22:44:28 +0100
committerAlan Pearce2014-07-12 22:51:24 +0100
commit1ddedd165d9342866f7592a4d46fa8c3c48c150c (patch)
treeb8f1095b16b50193aaf60317c9e145947ecc41ab /tag-emacs/emacs.d
parentfac5dc322f8860308e4c9991e501b292f34dc92c (diff)
downloaddotfiles-1ddedd165d9342866f7592a4d46fa8c3c48c150c.tar.lz
dotfiles-1ddedd165d9342866f7592a4d46fa8c3c48c150c.tar.zst
dotfiles-1ddedd165d9342866f7592a4d46fa8c3c48c150c.zip
Emacs: Use MMM for toml in markdown front matter
Diffstat (limited to 'tag-emacs/emacs.d')
-rw-r--r--tag-emacs/emacs.d/init.el9
1 files changed, 8 insertions, 1 deletions
diff --git a/tag-emacs/emacs.d/init.el b/tag-emacs/emacs.d/init.el
index 4c96f57..bc131f5 100644
--- a/tag-emacs/emacs.d/init.el
+++ b/tag-emacs/emacs.d/init.el
@@ -1110,7 +1110,14 @@
                     :back "\\([\"']\\|SQL\\);?"
                     :face mmm-code-submode-face)))
                 (mmm-add-mode-ext-class 'php-mode "\\.php$" 'php-sql)
-                (setq php-sql-mmm-submode-enabled t))))
+                (setq php-sql-mmm-submode-enabled t)))
+            (mmm-add-classes
+             '((markdown-toml
+                :submode toml-mode
+                :face mmm-declaration-submode-face
+                :front "\\`+++[\n\r]+"
+                :back "^+++$")))
+            (mmm-add-mode-ext-class 'markdown-mode nil 'markdown-toml))
   :init (setq mmm-global-mode 'maybe))
 
 ;;;; Windows & Frames