summary refs log tree commit diff
path: root/emacs/custom
diff options
context:
space:
mode:
Diffstat (limited to 'emacs/custom')
-rw-r--r--emacs/custom/my-prog.el7
1 files changed, 6 insertions, 1 deletions
diff --git a/emacs/custom/my-prog.el b/emacs/custom/my-prog.el
index df56223..7cbc2c7 100644
--- a/emacs/custom/my-prog.el
+++ b/emacs/custom/my-prog.el
@@ -118,10 +118,15 @@
   (add-hook 'before-save-hook #'eglot-format-buffer 100 t))
 
 ;; ensure we load eglot for some specific modes
-(dolist (hook '(go-mode-hook nix-mode-hook))
+(dolist (hook '(go-mode-hook nix-mode-hook rust-mode-hook))
   (add-hook hook 'eglot-ensure)
   (add-hook hook #'my/eglot-install-save-hook))
 
+(require 'rustic)
+(setq rustic-lsp-server 'rust-analyzer
+      rustic-lsp-client 'eglot
+      rustic-format-on-save t)
+
 (provide 'my-prog)
 
 ;;; my-prog.el ends here