Only install treesitter languages once.

This commit is contained in:
Tom Alexander 2023-05-27 12:37:49 -04:00
parent 5096449cf5
commit 57ddfaad6f
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
2 changed files with 2 additions and 2 deletions

View File

@ -44,7 +44,7 @@
:init
(add-to-list 'major-mode-remap-alist '(rust-mode . rust-ts-mode))
(add-to-list 'treesit-language-source-alist '(rust "https://github.com/tree-sitter/tree-sitter-rust"))
(treesit-install-language-grammar 'rust)
(unless (treesit-ready-p 'yaml) (treesit-install-language-grammar 'rust))
:config
;; Add keybindings for interacting with Cargo
(use-package cargo

View File

@ -18,7 +18,7 @@
:init
(add-to-list 'major-mode-remap-alist '(yaml-mode . yaml-ts-mode))
(add-to-list 'treesit-language-source-alist '(yaml "https://github.com/ikatyang/tree-sitter-yaml"))
(treesit-install-language-grammar 'yaml)
(unless (treesit-ready-p 'yaml) (treesit-install-language-grammar 'yaml))
)
(provide 'lang-yaml)