Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

3
  • That's my point. The which command with no extra arguments, listed /opt/local/bin/python, however when I executed python /usr/local/bin/python is executed. There are no aliases according to alias. type does get it right though (/usr/local/bin) but why does it execute this file and not the other which comes before it in the PATH? Commented Jul 22, 2011 at 10:56
  • Brendan: See my above comment (under laebshade's answer). Also, what gives type -a which and echo $PATH? Commented Jul 22, 2011 at 11:30
  • 1
    I voted this the answer since I hadn't heard of the type command before. Thanks. Commented Jul 22, 2011 at 12:11