OxideBSD
APROPOS(1) General Commands Manual APROPOS(1)

apropos, whatis — search the manual page index

apropos [-afkt] [-C file] [-M path] [-m path] [-O outkey] [-S arch] [-s section] expression ...

whatis [-a] [-C file] [-M path] [-m path] [-S arch] [-s section] name ...

The apropos utility searches the index of each manual directory, the file oxdoc.db that makewhatis(8) builds, and lists the pages matching expression: their names, section and one-line description. The whatis utility lists the pages with a name among their names.

The options are as follows:

Show the matching pages in full, through man(1), instead of listing them.
file
Read the manual directories from file instead of /etc/man.conf.
Search as whatis does: each argument is a whole word to find in the pages' names, ignoring case.
Search as apropos does, the default.
path
Search the indexes of the colon-separated manual directories in path instead of the default ones.
path
Search the directories in path before the others.
outkey
Show the values of the key outkey for each page instead of its description, sorted and separated by ‘#’.
arch
Only list pages for the architecture arch, or for any.
section
Only list pages of section.
Search the full text: each word in expression is the term Tx=word.

An expression is made of terms, joined by -a (and) and -o (or). Two terms without an operator between them are joined by -o, and -a binds more tightly. Parentheses, as separate arguments, group terms.

A term has the form [key[,key ...](= | ~)]value. With =, it is true of a page with a value of one of the keys containing value, ignoring case; with ~, of a page with a value matching the extended regular expression value (see re_format(7)), with case, unless -i comes before the term. Without a key, a term searches the names and the description. A term without = or ~ searches the names and the description with value as a regular expression, ignoring case.

The keys are the mdoc(7) macros whose values makewhatis(8) records, and a few others:

Nm the page's names
Nd its one-line description
its section
its architecture
Sh, Ss its section and subsection titles, except the standard ones
Xr its cross references, as name(section)
Fl, Cm, Ar, Ic flags, modifiers, arguments and commands
Ev, Pa, Er environment variables, paths and error numbers
In, Lb header files and libraries
Fn, Fa, Ft function names, arguments and types
Va, Vt, Dv variables, types and constants
An, Lk, Mt authors, links and mail addresses
Cd, Ms, Tn configuration, symbols and trade names
Em, Sy, Li emphasized, bold and literal text
St, At, Bx, Fx, Nx, Ox, Dx, Bsx standards and systems
Tx every word of the page's text, in lower case
all of the above but Tx

Pages written in man(7) only have names, a description and full text.

The manual directories, as for man(1).

oxdoc.db
the index in each manual directory
/etc/man.conf
the manual directories

The apropos utility exits 0 if it found a page, and 1 if it found none or the arguments were wrong.

Pages mentioning file systems in their names or descriptions:

$ apropos 'file ?system'

Pages in section 3 using both optind and optarg:

$ apropos -s 3 Va=optind -a Va=optarg

Pages referring to getty(8), with those references:

$ apropos -O Xr Xr=getty

Pages whose text mentions a password:

$ apropos -t password

man(1), man.conf(5), makewhatis(8)

The apropos and whatis utilities first appeared in 2BSD. This implementation was written for OxideBSD; its expressions and keys follow mandoc(1)'s apropos.

The names of a page are listed in the order its NAME section gives them, which is not always the order of other systems.

September 27, 2026 OxideBSD