4

Typing export $PATH in Mountain Lion's Terminal returns

  /usr/local/bin:/usr/local/heroku/bin:/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/Library/Frameworks/Python.framework/Versions/Current/bin:/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/git/bin:/usr/local/MacGPG2/bin`

However, my /etc/paths file shows:

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

Is this a problem?

1
  • /usr/local/bin found twice??
    – Weishi Z
    May 26, 2016 at 22:55

1 Answer 1

4

It's perfectly OK.

As you log in, your PATH is constructed from several different sources. Some are system wide, others are user specific: the .profile file in your home folder, for example, is a common way for adding paths to your PATH for your account only.

You can see that the paths from /etc/paths are still there, in the middle of your PATH but some stuff has been added. /usr/local/MacGPG2/bin for example has been added by macGPG2 when you installed it.

1
  • 1
    what's the order of loading those PATH?
    – Weishi Z
    May 26, 2016 at 22:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .