Content-type: text/html
which - Locates a program file including aliases and paths
which program...
The which command takes a list of program names and looks for the files that would be executed if these names were given as commands.
Each program argument is expanded if it is aliased and searched for along your path. Both the aliases and path are taken from your .cshrc file. If you do not have a .cshrc file, the path is the current PATH from your environment.
The
which
command is written in
csh
script language and only works in the C shell. The
ksh
program offers the built-in commands
type
and
whence
that perform the same function as
which.
The
sh
built-in command
type
can also
be used.
Read at beginning of execution by each shell.
A diagnostic is given if an executable file with the argument name was
not found in the path.
Commands: whereis(1)