Telling Where a Command is Executed
On HP-UX,
there are a number of ways to find out whether a
command is an alias, a program, a shell script, or a
built-in shell command:
- The whence command is a Korn Shell feature
that tells how a name would be interpreted by the shell:
it detects commands and aliases, and searches
your path.
- The type command is like whence -v and works in
all shells on HP-UX and AIX. It works in ksh and sh
on OSF1, SunOS, Solaris, SCO, A/UX, NCRSVR4, and LINUX, and it
works in the NuTCracker development environment on Windows/NT.
- The which command
can tell if a name is an alias or on your path; it cannot
detect built-in commands. which is a program available in
all shells on HP-UX, but may be a C shell feature only on other systems.
- The whereis command locates the source, binary
and manual files for a program, searching a list of standard
places.
- The what command searches a given file for
SCCS identification information (Source Code Control System),
such as what compiler was used to create it.
- The man command
gives you help with a program, if the program has a man page.
On MPE
you can use the :Help command to find where
on your HPPATH a particular program or command file
is located:
:help qedit
QEDIT.PUB.ROBELLE (Program file)