Re: "cmd.exe /c echo '%ProgramFiles%' returned empty string

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2011-11-11 at 07:33 -0600, Usurp wrote:

> Having '.' and $HOME in $PATH can lead to subtle failures,
> if you create a file that has the same name as an existing command.
> 
> Simple example: the updatedb command from mlocate
> 
That is why, if you're wise, you always run 'which' to check check
whether the script/program name you just thought up is going to clash
with anything else. Its also why I said "add them to the right hand
end", as in:

export PATH="$PATH:$HOME/bin:."

$PATH is searched left to right, so doing it this way guarantees that
pre-existing stuff takes precedence over anything you wrote without
first checking for name clashes.

Martin





[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux