diff options
author | Thomas Voss <thomas.voss@humanwave.nl> | 2025-06-11 14:59:44 +0200 |
---|---|---|
committer | Thomas Voss <thomas.voss@humanwave.nl> | 2025-06-11 14:59:44 +0200 |
commit | fad74e4384176f8cf98c86cfbf5c0468c0f49dce (patch) | |
tree | fd749a043dfa08b6310cf40d51bfc4dac60d1c19 | |
parent | 4ae33a0cf9bcb25141954d17fb9dcf3f44edfef3 (diff) |
emacs: Add Markdown Tree-Sitter support
-rw-r--r-- | .config/emacs/modules/mm-treesit.el | 55 |
1 files changed, 40 insertions, 15 deletions
diff --git a/.config/emacs/modules/mm-treesit.el b/.config/emacs/modules/mm-treesit.el index 02f906a..68f3bb0 100644 --- a/.config/emacs/modules/mm-treesit.el +++ b/.config/emacs/modules/mm-treesit.el @@ -15,21 +15,41 @@ (setopt treesit-font-lock-level 4) (setopt treesit-language-source-alist - '((awk "https://github.com/Beaglefoot/tree-sitter-awk") - (c "https://github.com/tree-sitter/tree-sitter-c") - (cpp "https://github.com/tree-sitter/tree-sitter-cpp") - (css "https://github.com/tree-sitter/tree-sitter-css") - (go "https://github.com/tree-sitter/tree-sitter-go") - (gomod "https://github.com/camdencheek/tree-sitter-go-mod") - (gsp "git://git.thomasvoss.com/tree-sitter-gsp.git") - (html "https://github.com/tree-sitter/tree-sitter-html") - (java "https://github.com/tree-sitter/tree-sitter-java") - (javascript "https://github.com/tree-sitter/tree-sitter-javascript") - (python "https://github.com/tree-sitter/tree-sitter-python") - (typescript "https://github.com/tree-sitter/tree-sitter-typescript" - "master" "typescript/src") - (vim "https://github.com/tree-sitter-grammars/tree-sitter-vim") - (vue "https://github.com/ikatyang/tree-sitter-vue"))) + '((awk + "https://github.com/Beaglefoot/tree-sitter-awk") + (c + "https://github.com/tree-sitter/tree-sitter-c") + (cpp + "https://github.com/tree-sitter/tree-sitter-cpp") + (css + "https://github.com/tree-sitter/tree-sitter-css") + (go + "https://github.com/tree-sitter/tree-sitter-go") + (gomod + "https://github.com/camdencheek/tree-sitter-go-mod") + (gsp + "git://git.thomasvoss.com/tree-sitter-gsp.git") + (html + "https://github.com/tree-sitter/tree-sitter-html") + (java + "https://github.com/tree-sitter/tree-sitter-java") + (javascript + "https://github.com/tree-sitter/tree-sitter-javascript") + (markdown + "https://github.com/tree-sitter-grammars/tree-sitter-markdown" + "split_parser" "tree-sitter-markdown/src") + (markdown-inline + "https://github.com/tree-sitter-grammars/tree-sitter-markdown" + "split_parser" "tree-sitter-markdown-inline/src") + (python + "https://github.com/tree-sitter/tree-sitter-python") + (typescript + "https://github.com/tree-sitter/tree-sitter-typescript" + "master" "typescript/src") + (vim + "https://github.com/tree-sitter-grammars/tree-sitter-vim") + (vue + "https://github.com/ikatyang/tree-sitter-vue"))) ;;; Install Missing Parsers @@ -79,6 +99,11 @@ The parsers are taken from `treesit-language-source-alist'." :ensure t :mode "\\.vue\\'") +;; NOTE: This package doesn’t autoload its ‘auto-mode-alist’ entries +(use-package markdown-ts-mode + :ensure t + :mode "\\.md\\'") + ;;; Prefer Tree-Sitter Modes |