Refresh exec-path & shell-file-name

When loading envvars, since `load-env-vars` only affects the environment
and not Emacs' variables.
This commit is contained in:
Henrik Lissner 2019-04-01 13:15:15 -04:00
parent 5b43b2840b
commit a6cc66e21e
No known key found for this signature in database
GPG Key ID: 5F6C0EA160557395

View File

@ -453,10 +453,14 @@ to least)."
(user-error "Your package autoloads are missing! Run `bin/doom refresh' to regenerate them")))
;; Load shell environment
(when (and (not noninteractive)
(when (and (or (daemonp) (display-graphic-p))
(file-readable-p doom-env-file)
(require 'load-env-vars nil t))
(load-env-vars doom-env-file)))
(load-env-vars doom-env-file)
(setq exec-path (append (split-string (getenv "PATH") ":")
(list exec-directory))
shell-file-name (or (getenv "SHELL")
shell-file-name))))
(require 'core-lib)
(require 'core-modules)