feat(language/protobuf): format non-buf protobuf files with clang-format

This commit is contained in:
2022-07-20 21:32:47 +01:00
parent 72c33e7b37
commit b92bd7b19e

View File

@@ -26,7 +26,8 @@
(indent-tabs-mode . nil)) t)
;; Lint and format with buf if file is in a buf project.
(when (flycheck-protobuf-buf-project-root)
(if (not (flycheck-protobuf-buf-project-root))
(clang-format-on-save-mode t)
(setq-local flycheck-checker 'protobuf-buf)
(buf-format-on-save-mode t))