blob: 5c391ceaae2b57b9e4b8d33afea243e4b1cc4f1d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
;;; treesitter-config.el --- Treesitter Code Highlighting Configuration -*- lexical-binding: t; -*-
;; author: Craig Jennings <c@cjennings.net>
;;; Commentary:
;; Tree-sitter's now built into Emacs 29+!
;;; Code:
;; ------------------ Installation And Configuration -----------------
(use-package tree-sitter
:defer .5)
;; ----------------------- Grammar Installation ----------------------
;; installs tree-sitter grammars if they're absent
(use-package treesit-auto
:defer .5
:custom
(treesit-auto-install t)
;; (treesit-auto-install 'prompt) ;; optional prompt instead of auto-install
:config
(treesit-auto-add-to-auto-mode-alist 'all)
(global-treesit-auto-mode))
(provide 'treesitter-config)
;;; treesitter-config.el ends here.
|