Now for something completely different
Ben Webb
brwebb at transmuto.com
Thu Jul 6 16:01:40 CDT 2000
Here are comments and a better fix.
>MS-DOS assumes that the current (or active) directory
>is in the search path. Unix/Linux makes no assumption.
>When you type ./ you are telling the system to look into
>the current directory and run the executable there. MS-DOS
>automatically appends . to your search path. As to changing
>the behaviour of Linux/Unix, I cannot help other than to offer
All true, and well stated.
>this relatively lame solution... add all your directories that
>have your executables to your path. This could
>reduce system performance and could cause you to run
>executables with the same filename from other directories
>if those other directoires appear in the path statement
>before the current directory. Maybe someone else has
>a fix for this...
Actually, you can just put the "." in your path, as in:
$ export PATH=$PATH:.
This isn't generally risky except when running as root - something that should only be done when
absolutely necessary.
More specifically for you situation, Dana, go to the command line and start a vi session to edit
your .bashrc
$ vi .bashrc
Hunt around and see if you see a line something like (this will not be it exactly):
export PATH=/usr/bin:/usr/local/bin:/usr/X1186/bin:/usr/games/bin
If you do, stick a ":." on the end of it (no quotes, of course). If you don't, put this on the very
last line:
export PATH=$PATH:.
Save it, then source the file by entering
. .bashrc
You should be fixed forever.
***********IMPORTANT NOTE*******************
Only do this if you are NOT running as root. If you are logging in as root, ignore everything I
have told you and create an account! This will probably fix your problem, and it is by far best
practice. You should NEVER log in as root unless you are doing something that makes it necessary.
Benjamin R. Webb
More information about the Kclug
mailing list