fix bug of some versions of emacs and tree-sitter environment
This commit is contained in:
3 files changed
+5
-2
No files matched your search
@@ -52,6 +52,6 @@ Do this recursively for subdirectories of DIR."
|
||||
;; "compat" "transient"
|
||||
(dolist (pkg '("compat" "transient"))
|
||||
(unless (locate-library pkg)
|
||||
(add-pkg-in-pkg-dir)))
|
||||
(add-pkg-in-pkg-dir pkg)))
|
||||
|
||||
(provide 'init-package)
|
||||
@@ -4,6 +4,9 @@
|
||||
(and (fboundp 'treesit-available-p) (treesit-available-p))
|
||||
"Built-in `treesit' available.")
|
||||
|
||||
(setq treesit-extra-load-path
|
||||
(list (file-name-concat creature/config-dir "tree-sitter")))
|
||||
|
||||
(when creature/treesit-available
|
||||
(unless (featurep 'treesit) (require 'treesit))
|
||||
(when (treesit-ready-p 'javascript)
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
(add-to-list 'auto-mode-alist '("\\.ts\\'" . typescript-ts-mode))
|
||||
(add-to-list 'auto-mode-alist '("\\.tsx\\'" . tsx-ts-mode)))
|
||||
|
||||
(add-subdirs-to-load-path (expand-file-name "optional-pkg" creature/config-dir))
|
||||
(add-dir-and-subdirs-to-load-path (expand-file-name "optional-pkg" creature/config-dir))
|
||||
(require 'typescript-mode)
|
||||
|
||||
(define-derived-mode typescript-tsx-mode typescript-mode "Tsx"
|
||||
|
||||
Reference in new issue
Block a user