summaryrefslogtreecommitdiff
path: root/dir-locals/eglot-rust-dir-locals.el
diff options
context:
space:
mode:
Diffstat (limited to 'dir-locals/eglot-rust-dir-locals.el')
-rw-r--r--dir-locals/eglot-rust-dir-locals.el6
1 files changed, 6 insertions, 0 deletions
diff --git a/dir-locals/eglot-rust-dir-locals.el b/dir-locals/eglot-rust-dir-locals.el
new file mode 100644
index 0000000..9fff9e8
--- /dev/null
+++ b/dir-locals/eglot-rust-dir-locals.el
@@ -0,0 +1,6 @@
+((rust-mode . ((eval . (eglot-ensure))
+ (eglot-workspace-configuration . ((:rust-analyzer . (:checkOnSave
+ (:command "clippy")))))
+ (rust-format-on-save . t)
+ (rust-format-goto-problem . t)
+ (rust-rustfmt-switches . ("--edition" "2021")))))