fix(lib): doom/{reload,upgrade}: ensure env matches session
This commit is contained in:
parent
a8ba8feecb
commit
9c6a5e9323
1 changed files with 19 additions and 12 deletions
|
@ -57,6 +57,13 @@ And jumps to your `doom!' block."
|
|||
(declare (indent 2))
|
||||
`(let ((default-directory doom-emacs-dir)
|
||||
(exec-path (cons doom-bin-dir exec-path)))
|
||||
;; Ensure the bin/doom operates with the same environment as this
|
||||
;; running session.
|
||||
(letenv! (("EMACS" (doom-path invocation-directory invocation-name))
|
||||
("EMACSDIR" doom-emacs-dir)
|
||||
("DOOMDIR" doom-user-dir)
|
||||
("DOOMLOCALDIR" doom-local-dir)
|
||||
("DEBUG" (and doom-debug-mode "1")))
|
||||
(with-current-buffer (compile ,command t)
|
||||
(let ((w (get-buffer-window (current-buffer))))
|
||||
(select-window w)
|
||||
|
@ -68,7 +75,7 @@ And jumps to your `doom!' block."
|
|||
(delete-window w)
|
||||
,on-success)
|
||||
,on-failure))
|
||||
nil 'local)))))
|
||||
nil 'local))))))
|
||||
|
||||
(defvar doom-reload-command "doom sync -B -e"
|
||||
"Command that `doom/reload' runs.")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue