Skip to content

Commit

Permalink
refactor(builtin): conditionally enable treesit stuff the MinEmacs way
Browse files Browse the repository at this point in the history
  • Loading branch information
abougouffa committed Oct 14, 2023
1 parent 6c562ac commit b50775d
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions core/me-builtin.el
Original file line number Diff line number Diff line change
Expand Up @@ -302,20 +302,22 @@
:after oc
:demand t)

(when (+emacs-features-p 'tree-sitter)
(use-package treesit
:straight (:type built-in)
:custom
(treesit-font-lock-level 4))

(use-package dockerfile-ts-mode
:straight (:type built-in)
:mode "/Dockerfile\\'")

(use-package cmake-ts-mode
:straight (:type built-in)
:mode "CMakeLists\\.txt\\'"
:mode "\\.cmake\\'"))
(unless (+emacs-features-p 'tree-sitter)
(push '(treesit dockerfile-ts-mode cmake-ts-mode) minemacs-disabled-packages))

(use-package treesit
:straight (:type built-in)
:custom
(treesit-font-lock-level 4))

(use-package dockerfile-ts-mode
:straight (:type built-in)
:mode "/Dockerfile\\'")

(use-package cmake-ts-mode
:straight (:type built-in)
:mode "CMakeLists\\.txt\\'"
:mode "\\.cmake\\'")

(use-package autoinsert
;; NOTE: When prompting (like in Keywords), hit M-RET when finished
Expand Down

0 comments on commit b50775d

Please sign in to comment.