diff options
Diffstat (limited to 'init/rust-setup.el')
-rw-r--r-- | init/rust-setup.el | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/init/rust-setup.el b/init/rust-setup.el deleted file mode 100644 index cc61718c1d7e..000000000000 --- a/init/rust-setup.el +++ /dev/null @@ -1,23 +0,0 @@ -(require 'company) -(require 'eglot) -(require 'rust-mode) - -;; LSP configuration: -(defvar rust-eglot-initialized nil) -(add-hook 'rust-mode-hook (lambda () - (unless rust-eglot-initialized - (call-interactively #'eglot) - (setq rust-eglot-initialized t)))) - -;; Enable cargo-related (C-c C-c C-...) commands. -(add-hook 'rust-mode-hook #'cargo-minor-mode) - -;; Configure autocompletion for rust -(add-hook 'rust-mode-hook #'company-mode) -(define-key rust-mode-map (kbd "TAB") #'company-indent-or-complete-common) -(setq company-tooltip-align-annotations t) - -;; Ensure long compiler errors don't flow out of the screen (very annoying!) -(add-hook 'cargo-process-mode-hook #'visual-line-mode) - -(provide 'rust-setup) |