doomemacs/modules/lang/nix/config.el
Henrik Lissner 7a81f46b39
Refactor lang/nix
+ Move set-company-backend! out of conditional (it is an autodef, meaning it will simply no-op if the company module is disabled)
+ Removed helm-nixos-options config, because `helm-nixos-options` is already autoloaded by the package
+ Simplify map! usage
+ Move nix-mode to the top, as it is the focal package of this module
2018-07-17 13:23:33 +02:00

21 lines
561 B
EmacsLisp

;;; lang/nix/config.el -*- lexical-binding: t; -*-
(after! nix-mode
(set-company-backend! 'nix-mode 'company-nixos-options)
(map! :map nix-mode-map
:localleader
:n "f" #'nix-update-fetch
:n "p" #'nix-format-buffer
:n "r" #'nix-repl-show
:n "s" #'nix-shell
:n "b" #'nix-build
:n "u" #'nix-unpack
(:when (featurep! :completion helm)
:n "o" #'helm-nixos-options)))
(def-package! nix-update
:commands (nix-update-fetch))
(def-package! nix-repl
:commands (nix-repl-show))