My ~/etc/path looks as follows:
/usr/local/bin /usr/bin /bin /usr/sbin /sbin The Problem:
When I type echo $PATH into terminal, I get back:
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin And this persists for every application started in the terminal. For instance, if I type emacs, and then do:
M-x getenv PATH My output is:
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin However, if I start up emacs using launchpad instead of terminal and once again enter M-x getenv PATH, my output is instead /usr/bin:/bin:/usr/sbin:/sbin.
As you can see my change to ~/etc/path, which was the addition of /usr/local/bin, is missing.
Another Example:
I use a Firefox plugin called vimperator which emulates vim functionality in Firefox. It has a feature that allows the user to edit webpage input in vim. However, this does not seem to work on OS X. On a hunch I type the command !echo $PATH into vimperator and see the following: /usr/bin:/bin:/usr/sbin:/sbin. Of course, since the symlink called gvim, which points to macvim, was created and placed into /usr/local/bin by brew, this behavior makes sense. What I don't understand is why the PATH is read the way it is.
Solutions that I have tried:
- I have obviously restarted my machine.
EDIT (As requested by now deleted comment):
using sysctl user.cs_path in the terminal brings up:
user.cs_path: /usr/bin:/bin:/usr/sbin:/sbin