echo PATH versus sudo vi /etc/paths

rjCooper

Registered
Command line experts,

So, I've googled this with no luck and could use some help:

I am seeing the following when I look at PATH:

Macintosh-7:~ Robert$ echo $PATH
/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin:/usr/X11/bin:/Users/Robert/gae/google_appengine

But when I open paths with vi, I don't see all the same items:

Macintosh-7:~ Robert$ sudo vi /etc/paths

/usr/bin
/bin
/usr/sbin
/sbin
/usr/local/bin

Where might I find these additional elements set?
/usr/local/git/bin:
/usr/X11/bin:
/Users/Robert/gae/google_appengine


I googled quite a bit trying to find what other files or variables might supplement etc/paths but haven't found an answer. I have also searched my hard drive quite a bit with find and whereis, but to no luck. I need to edit the last item:

/Users/Robert/gae/google_appengine

And also, just noticing in writing this post, the "-7" in my prompt:
Macintosh-7
Probably a simple thing but what does the "-7" refer to?

thanks
 
Does it matter? You can set it your self on your .bashrc (or what ever your shell interpreter's startup file is). If it is bash, it reads /etc/profile, /etc/bashrc and then your .profile and .bashrc files.

Set path with commands

PATH=/first/directory:/second/directory:/third/directory
export PATH

or if you like to add new directories but not to loose old,

PATH=/first/directory:/second/directory:/third/directory:$PATH
export PATH
 
Back
Top