which, whereisdisplay full path name for executable command |
Command |
which
[-a
] command ...
whereis
command ...
which
looks through the directories
in the search path, and displays the name of the first executable file that
matches command.
which
is intended to find commands that are executed when
the MKS KornShell is not being used.
The whereis
command is equivalent to specifying
which
-a
.
-a
displays all matching executable files from every directory in
PATH
, not just the first match. This can help
you find conflicts between two executables of the same name.
PATH
contains a list of directories for which
to search
when looking for command.
0
An appropriate executable file can be found with the current
PATH
.
1
Failure due to any of the following:
.ksh
or .sh
files. For this reason,
whence
is recommended when you are
using the MKS KornShell.