WHICHMAN(1) | General Commands Manual | WHICHMAN(1) |
whichman - show the location of a man page using a fault tolerant approximate matching algorithm
whichman [-#ehIp][-t#] man-page-name
whichman is a "which" alike search command for man pages. whichman searches the MANPATH environment variable. If this variable is not defined, then it uses /usr/share/man:/usr/man:/usr/X11R6/man: /usr/local/share/man:/usr/local/man by default.
Unlike "which" this program does not stop on the first match. The name should probably have been something like whereman as this is not a "which" at all. whichman shows all man-pages that match and allows you to identify the different sections to which the pages belong.
whichman can handle international manpage path names for different languages. Man pages in different languages may be stored in .../man/<country_code>/man[1-9]/...
By default, whichman does fault tolerant approximate string matching. With a default tolerance level of: (strlen(searchpattern) - number of wildcards)/6 + 1
The search key may contain the wildcards * and ? (but see -e option):
The last argument to whichman is not parsed for options as the program needs at least one man-page-name argument. This means that whichman -x will not complain about a wrong option but search for the man-page named -x.
whichman print
This will e.g. find the man-pages:
/usr/share/man/man1/printf.1.gz
/usr/share/man/man3/printf.3.gz
/usr/share/man/man3/rint.3.gz
The wildcards '?' and '*' can not be escaped. These characters function always as wildcards. This is however not a big problem since there is hardly any man-page that has these characters in its name.
Guido Socher (guido@linuxfocus.org)
April 1998 | Search utilities |