I just discovered that the which command on my snow leopard OS is lieing to me. I have had a succession of problems with installing various versions of perl which then fail with cpan, all in all a frustrating experience. That means I have perl installed in multiple places. I have been trying to make the one I like the default. I tried using alias, changing the path, putting a symbolic link to my preferred version in my ~/bin directory (which is always at the front of my $PATH) and the "which" command keeps telling me that /usr/bin/perl is the magic one that will be executed. I finally got suspicious and tried to get perl to tell me where it lived. perl -e 'print "$0\n";' was unhelpful; perl -e '"print $^X\n";' was unhelpful. Finally I remembered @INC and tried these two commands which should give identical results if 'which' can be trusted:<br>
<br>`which perl` -e 'print "@INC\n";'<br> perl -e 'print "@INC\n";'<br>
<br>Instead these commands gave me totally different results indicating two different installations of perl. It turns out that my redirections were working but "which" wasn't seeing them.<br><br>What the heck is wrong with the "which" command on OSX? Why do "bash" and "which" disagree on the actual path of the command to run? What is the point of having a "which" command if it doesn't match.<br>
<br>Regards,<br><br>Steve<br><br>