Consume top-level emacs attribute

Refactor `nix/rebuild-emacs` to consume newly defined top-level emacs
attribute.
This commit is contained in:
William Carroll 2020-03-04 19:25:13 +00:00
parent b0dfa088a5
commit dec005ea34

View file

@ -21,12 +21,13 @@
(use-package nix-mode
:mode "\\.nix\\'")
;; TODO(wpcarro): Ensure the sub-process can resolve <briefcase>.
(defun nix/rebuild-emacs ()
"Use nix-env to rebuild wpcarros-emacs."
(interactive)
(start-process "nix-build/<briefcase>.emacs" "*nix-build/<briefcase>.emacs*"
"nix-env" "-f" (f-join (getenv "BRIEFCASE") "emacs") "-i")
(display-buffer "*nix-build/<briefcase>.emacs*"))
(start-process "nix-build/<briefcase/emacs>" "*nix-build/<briefcase/emacs>*"
"nix-env" "-f" "<briefcase>" "-iA" "emacs")
(display-buffer "*nix-build/<briefcase/emacs>*"))
(defun nix/sly-from-briefcase (attribute)
"Start a Sly REPL configured with a Lisp matching a derivation