Subject: RE: lynx browser
To: None <jwinter@ticnet.com>
From: Steve Revilak <revilak@umbsky.cc.umb.edu>
List: port-mac68k
Date: 04/07/2000 19:54:16
> I have installed lynx and it was put into /usr/pkg/bin. This directory
> also contains gs (ghostscript).  When I execute gs I have no problem
> but, when I execute lynx I get command not found..
> 
> echo $PATH reveals /usr/pkg/bin is in the path...why is unix finding gs
> and not lynx.
> 
> there are both in the same directory...

Silly question.  Was this a case of 1) installing the package and 2)
trying to use it immediately  afterwards?

If the answer to silly question is yes, I'll go on to the silly
presumption that you're using a C shell (I'm not sure of the
semantics of Bourne variants here).

When invoked, the shell will look in the directories listed in PATH
for executables, then stores a list of those executable in a table. 
This allows the shell to find commands more quickly .. since it doesn't
have to search through each of the path directories every time you give
a command.

The flip side -- if you add an executable then immediately try to use
it, the shell won't know it's there.  You need to force it to rebuild
it's command table by giving the "rehash" command.

Logging out then logging back in will also have the same effects. 
Another alternative is to fully qualify the name to the executable.

Now for my own curiosity -- so bash/sh behave similarly here?

Hope that helps.

=-=-=-=-=-=-=-=-=-=-=-=
Steve Revilak
revilak@umbsky.cc.umb.edu