feat(format): add :lang gdscript formatter
This commit is contained in:
parent
a9b4f6e219
commit
12c901cf28
2 changed files with 8 additions and 0 deletions
|
@ -13,6 +13,9 @@
|
||||||
(set-lookup-handlers! 'gdscript-mode
|
(set-lookup-handlers! 'gdscript-mode
|
||||||
:documentation #'gdscript-docs-browse-symbol-at-point)
|
:documentation #'gdscript-docs-browse-symbol-at-point)
|
||||||
|
|
||||||
|
(when (executable-find "gdformat")
|
||||||
|
(set-formatter! 'gdformat '("gdformat" "-") :modes '(gdscript-mode)))
|
||||||
|
|
||||||
(when (modulep! +lsp)
|
(when (modulep! +lsp)
|
||||||
(add-hook 'gdscript-mode-local-vars-hook #'lsp! 'append))
|
(add-hook 'gdscript-mode-local-vars-hook #'lsp! 'append))
|
||||||
|
|
||||||
|
|
5
modules/lang/gdscript/doctor.el
Normal file
5
modules/lang/gdscript/doctor.el
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
;;; lang/gdscript/doctor.el -*- lexical-binding: t; -*-
|
||||||
|
|
||||||
|
(when (modulep! :editor format)
|
||||||
|
(unless (executable-find "gdformat")
|
||||||
|
(warn! "Couldn't find gdformat. Formatting will be disabled.")))
|
Loading…
Add table
Add a link
Reference in a new issue