I'm running a GUI Emacs compiled from the master
git branch on MacOS El Capitan. I'm using the package exec-path-from-shell
to set several environment variables I have configured in my ~/.zshenv
file. However, none of them inherited in Emacs. GOPATH
and SHELL
are not set and PATH
is not the PATH I have configured in my `~/.zshenv Currently I have the package configured with
(use-package exec-path-from-shell
:ensure t
:defer f
:config
(exec-path-from-shell-copy-env "GOPATH")
(exec-path-from-shell-copy-env "SHELL")
(exec-path-from-shell-copy-env "PATH")
(when (memq window-system '(mac ns x))
(exec-path-from-shell-initialize)))
After launching Emacs, M-x getenv
for PATH
returns /usr/bin:/usr/sbin/:/bin/:/sbin
However, executing shell-command
via M-!
with zsh -l -i -c 'echo $PATH
returns the PATH as I have set it in my ~/.zshenv
file.
The ~/.zshenv
looks like
export PATH="/Users/idclark/anaconda/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/texbin:/Applications/Postgres.app/Contents/Versions/9.4/bin:/Users/idclark/Library/Android/sdk/tools:/Users/idclark/Library/Android/sdk/platform-tools"
export JAVA_HOME="$(/usr/libexec/java_home)"
export MANPATH="/usr/local/man:$MANPATH"
export NVM_DIR="~/.nvm"
export GOPATH="/Users/idclark/go/bin"
Is this a problem with my zsh config or how how I'm initializing the exec-path-from-shell
package?