Enhance nix experience in emacs

This commit is contained in:
Nathan McCarty 2022-09-10 17:44:37 -04:00
parent 13973b3641
commit b250c1d13a
Signed by: thatonelutenist
GPG Key ID: D70DA3DD4D1E9F96
3 changed files with 21 additions and 0 deletions

View File

@ -332,6 +332,13 @@ work if it thinks it needs to."
lsp-rust-analyzer-diagnostics-enable-experimental t
lsp-rust-analyzer-display-chaining-hints t))
(after! lsp-mode
(add-to-list 'lsp-language-id-configuration '(nix-mode . "nix"))
(lsp-register-client
(make-lsp-client :new-connection (lsp-stdio-connection '("rnix-lsp"))
:major-modes '(nix-mode)
:server-id 'nix)))
(use-package! markdown-mode
:mode ("README\\.md" . gfm-mode)
:hook (markdown-mode . variable-pitch-mode)

View File

@ -514,6 +514,16 @@ Most of these are defaults, but I like having them explicit for my sanity
lsp-rust-analyzer-diagnostics-enable-experimental t
lsp-rust-analyzer-display-chaining-hints t))
#+end_src
** Nix
Use rnix-lsp
#+begin_src emacs-lisp
(after! lsp-mode
(add-to-list 'lsp-language-id-configuration '(nix-mode . "nix"))
(lsp-register-client
(make-lsp-client :new-connection (lsp-stdio-connection '("rnix-lsp"))
:major-modes '(nix-mode)
:server-id 'nix)))
#+end_src
* Composition
Modes for handling plain text and prose
** Markdown

View File

@ -22,6 +22,10 @@
aspellDicts.en
aspellDicts.en-science
aspellDicts.en-computers
# For nix
rnix-lsp
manix
nix-doc
# Desktop file for org-protocol
(makeDesktopItem {
name = "org-protocol";