Click to See Complete Forum and Search --> : Adding to $PATH


Dark Ninja
09-24-2001, 07:42 PM
I recently was instructed to add /etc/filename/ to my path so anybody on the system could run the program in question (that is not relevent to this discussion). Anyway, I edited /etc/profile and added /etc/filename to the line that said:

$PATH=/usr/src:/usr/blah:/blah/blah

However, it does not seem to work. I am not able to just type in the program's name and have the program run. Anybody help me with that? Thanks.


Dark Ninja

X_console
09-24-2001, 07:59 PM
Your syntax is wrong. It should be:

export PATH=$PATH:/my/new/program

Save the file then type "source /etc/profile"

bdg1983
09-24-2001, 08:05 PM
You added /etc/filename to the path? Should it not be /etc/directory_name?

My /etc/profile has

PATH="/bin:/usr/bin:/scripts:./"

export PATH

Dark Ninja
09-25-2001, 09:23 AM
Sorry about that - it was the directory name that I added. I'll have to log into Linux later and check it out to make sure I have everything correct. Thanks for the help, though.


Dark Ninja