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

Re: Command Performance.




Tesla Coil wrote:
> 
> 11 Apr 2000, Kara & Steven Pritchard wrote:
> > I'll ask the obvious, is said path to said command in $PATH?
> and
> > Umm...  If it isn't in $PATH, why should it run?  Unix shells
> > don't run stuff in the current directory unless "." is in $PATH
> > (which is a security hole).  If you want to run foo in the current
> > directory, do "./foo".
> 
> I was saying was that, for example, I have the program
> foo in /mnt.  If my current directory is /home/bar,  I expect
> the command line "foo" to return "command not found"
> because /mnt is not in $PATH.  If foo were in /usr/bin,
> it would be in $PATH and execute as described above.
> 
> Remaining in /home/bar I enter the command "/mnt/foo"
> or, cd to /mnt then simply enter the command as "foo"--
> Both of these approaches also return "command not found."
> 
> If that is correct behavior, I have the opposite kind of
> problem with my fresh install of SuSE 6.4...

/mnt/foo should work, as long as the foo file is executable (chmod +x
it).  To run a file in your current directory (like the cd /mnt
example), you'll have to type "./foo"  You could add the current
directory (.) to your PATH, but that's just asking for trouble like
others have said.

--
To unsubscribe, send email to majordomo@luci.org with
"unsubscribe luci-discuss" in the body.