MacVim adds some variables to the environment with a potentially different
value than the existing one. For example ":!printenv" in MacVim shows me the
following for my PATH:
PATH=/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin
:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/MacGPG2/bin:/usr/texbin
But a few lines below the following appears:
PATH=/usr/bin:/bin:/usr/sbin:/sbin
Either definition might be picked up depending on the subshell. If I do ":!zsh
-c 'echo $PATH'", I get the first definition. If I do ":!sh -c 'echo $PATH'"
instead, I get the second definition.
This is a problem for me because I am using xelatex which tries to execute
another program in a shell which picks up the wrong PATH definition and cannot
find the program anymore.
Surprisingly, it works fine (with just a single PATH definition in the
environment) if I start MacVim with the mvim command from my interactive zsh.
I am using:
MacVim 7.4 (2013 Aug 10, compiled Nov 16 2014 19:08:01), Included patches: 1-258
zsh 5.0.7 (x86_64-apple-darwin14.0.0)
sh is GNU bash, version 3.2.53(1)-release (x86_64-apple-darwin14)
Original issue reported on code.google.com by j...@hyper-world.de on 5 Jan 2015 at 1:38
Original issue reported on code.google.com by
j...@hyper-world.de
on 5 Jan 2015 at 1:38