fix: doom/reload not restoring initial envvars

'doom/reload' should and cannot regenerate the user's envvar file,
because it's not typically running in your shell, but it should reload
your existing envvar file.

Fix #5399
Ref #5344
This commit is contained in:
Henrik Lissner 2021-10-01 18:12:34 +02:00
parent b58fad7eee
commit 0381c7868e

View file

@ -76,9 +76,8 @@ package list, and lastly, reloads your private config.el.
Runs `doom-after-reload-hook' afterwards." Runs `doom-after-reload-hook' afterwards."
(interactive) (interactive)
(mapc #'require (cdr doom-incremental-packages)) (mapc #'require (cdr doom-incremental-packages))
(doom--if-compile (format "%S sync" doom-bin) (doom--if-compile (format "%S sync -e" doom-bin)
(let ((doom-reloading-p t) (let ((doom-reloading-p t))
doom-env-file)
(doom-run-hooks 'doom-before-reload-hook) (doom-run-hooks 'doom-before-reload-hook)
(doom-initialize 'force) (doom-initialize 'force)
(with-demoted-errors "PRIVATE CONFIG ERROR: %s" (with-demoted-errors "PRIVATE CONFIG ERROR: %s"