feat(format): add :lang zig formatter
This commit is contained in:
parent
c2980d1d7b
commit
c7794ba06c
2 changed files with 5 additions and 1 deletions
|
@ -11,6 +11,7 @@
|
|||
:hook (zig-mode . rainbow-delimiters-mode)
|
||||
:config
|
||||
(setq zig-format-on-save nil) ; rely on :editor format instead
|
||||
(set-formatter! 'zigfmt '("zig" "fmt" "--stdin") :modes '(zig-mode))
|
||||
|
||||
(when (modulep! +lsp)
|
||||
(add-hook 'zig-mode-local-vars-hook #'lsp! 'append))
|
||||
|
|
|
@ -10,7 +10,10 @@
|
|||
"This module requires (:tools tree-sitter)")
|
||||
|
||||
(unless (executable-find "zig")
|
||||
(warn! "Couldn't find zig binary"))
|
||||
(warn! "Couldn't find zig binary")
|
||||
|
||||
(when (modulep! :editor format)
|
||||
(warn! "Formatting will be disabled")))
|
||||
|
||||
(when (modulep! +lsp)
|
||||
(unless (executable-find "zls")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue