about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBaitinq <manuelpalenzuelamerino@gmail.com>2022-10-24 16:18:56 +0200
committerBaitinq <manuelpalenzuelamerino@gmail.com>2022-10-24 16:18:56 +0200
commit5f7001a7796f470cb1d150b3b6054aba47a2518f (patch)
tree0ccd9fd96c93eb8488b6fea938a4fd03b45aa78f
parentDotfiles: Emacs: Disable lockfiles (diff)
downloadnixos-config-5f7001a7796f470cb1d150b3b6054aba47a2518f.tar.gz
nixos-config-5f7001a7796f470cb1d150b3b6054aba47a2518f.tar.bz2
nixos-config-5f7001a7796f470cb1d150b3b6054aba47a2518f.zip
Emacs: Add rust-mode rust support
Diffstat (limited to '')
-rw-r--r--dotfiles/.emacs13
-rw-r--r--hosts/home.nix2
2 files changed, 15 insertions, 0 deletions
diff --git a/dotfiles/.emacs b/dotfiles/.emacs
index 22be89d..2c3db3c 100644
--- a/dotfiles/.emacs
+++ b/dotfiles/.emacs
@@ -109,3 +109,16 @@
 
 (use-package lsp-haskell
   :ensure t )
+
+(use-package rust-mode
+	     : ensure t)
+
+(add-hook 'rust-mode-hook
+          (lambda () (setq indent-tabs-mode nil)))
+
+(setq rust-format-on-save t)
+
+(add-hook 'rust-mode-hook
+          (lambda () (prettify-symbols-mode)))
+
+(add-hook 'rust-mode-hook #'lsp)
diff --git a/hosts/home.nix b/hosts/home.nix
index e52f7a4..fd28d5d 100644
--- a/hosts/home.nix
+++ b/hosts/home.nix
@@ -150,6 +150,8 @@
 
         lsp-mode
         company
+        rust-mode
+        flycheck
         lsp-haskell
 
         nix-mode