.\" Automatically generated from an mdoc input file. Do not edit. .\" $Id: makewhatis.8,v 1.6 2017/05/17 22:27:12 schwarze Exp $ .\" .\" Copyright (c) 2011, 2012 Kristaps Dzonsons .\" Copyright (c) 2011, 2012, 2014, 2017 Ingo Schwarze .\" .\" Permission to use, copy, modify, and distribute this software for any .\" purpose with or without fee is hereby granted, provided that the above .\" copyright notice and this permission notice appear in all copies. .\" .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" .TH "MAKEWHATIS" "8" "May 17, 2017" "Debian" "System Manager's Manual" .nh .if n .ad l .SH "NAME" \fBmakewhatis\fR \- index UNIX manuals .SH "SYNOPSIS" .HP 11n \fBmakewhatis\fR [\fB\-aDnpQ\fR] [\fB\-T\fR\ \fButf8\fR] [\fB\-C\fR\ \fIfile\fR] .br .PD 0 .HP 11n \fBmakewhatis\fR [\fB\-aDnpQ\fR] [\fB\-T\fR\ \fButf8\fR] \fIdir\ ...\fR .br .HP 11n \fBmakewhatis\fR [\fB\-DnpQ\fR] [\fB\-T\fR\ \fButf8\fR] \fB\-d\fR\ \fIdir\fR [\fIfile\ ...\fR] .br .HP 11n \fBmakewhatis\fR [\fB\-Dnp\fR] [\fB\-T\fR\ \fButf8\fR] \fB\-u\fR\ \fIdir\fR [\fIfile\ ...\fR] .br .HP 11n \fBmakewhatis\fR [\fB\-DQ\fR] \fB\-t\fR\ \fIfile\ ...\fR .PD .SH "DESCRIPTION" The \fBmakewhatis\fR utility extracts keywords from UNIX manuals and indexes them in a database for fast retrieval by apropos(1), whatis(1), and man(1)'s \fB\-k\fR option. .PP By default, \fBmakewhatis\fR creates a database in each \fIdir\fR using the files \fBman\fR\fIsection\fR\fR/\fR[\fIarch\fR\fR/\fR]\fItitle\fR.\fIsection\fR and \fBcat\fR\fIsection\fR\fR/\fR[\fIarch\fR\fR/\fR]\fItitle\fR.\fB0\fR in that directory. Existing databases are replaced. If a directory contains no manual pages, no database is created in that directory. If \fIdir\fR is not provided, \fBmakewhatis\fR uses the default paths stipulated by man.conf(5). .PP The arguments are as follows: .TP 9n \fB\-a\fR Use all directories and files found below \fIdir ...\fR. .TP 9n \fB\-C\fR \fIfile\fR .br Specify an alternative configuration \fIfile\fR in man.conf(5) format. .TP 9n \fB\-D\fR Display all files added or removed to the index. With a second \fB\-D\fR, also show all keywords added for each file. .TP 9n \fB\-d\fR \fIdir\fR Merge (remove and re-add) \fIfile ...\fR to the database in \fIdir\fR. .TP 9n \fB\-n\fR Do not create or modify any database; scan and parse only, and print manual page names and descriptions to standard output. .TP 9n \fB\-p\fR Print warnings about potential problems with manual pages to the standard error output. .TP 9n \fB\-Q\fR Quickly build reduced-size databases by reading only the NAME sections of manuals. The resulting databases will usually contain names and descriptions only. .TP 9n \fB\-T\fR \fButf8\fR .br Use UTF-8 encoding instead of ASCII for strings stored in the databases. .TP 9n \fB\-t\fR \fIfile ...\fR Check the given \fIfiles\fR for potential problems. Implies \fB\-a\fR, \fB\-n\fR, and \fB\-p\fR. All diagnostic messages are printed to the standard output; the standard error output is not used. .TP 9n \fB\-u\fR \fIdir\fR Remove \fIfile ...\fR from the database in \fIdir\fR. If that causes the database to become empty, also delete the database file. .PP If fatal parse errors are encountered while parsing, the offending file is printed to stderr, omitted from the index, and the parse continues with the next input file. .SH "ENVIRONMENT" .TP 9n \fRMANPATH\fR A colon-separated list of directories to create databases in. Ignored if a \fIdir\fR argument or the \fB\-t\fR option is specified. .SH "FILES" .TP 8n \fImandoc.db\fR A database of manpages relative to the directory of the file. This file is portable across architectures and systems, so long as the manpage hierarchy it indexes does not change. .TP 8n \fI/etc/man.conf\fR The default man(1) configuration file. .SH "EXIT STATUS" The \fBmakewhatis\fR utility exits with one of the following values: .TP 8n 0 No errors occurred. .PD 0 .TP 8n 5 Invalid command line arguments were specified. No input files have been read. .TP 8n 6 An operating system error occurred, for example memory exhaustion or an error accessing input files. Such errors cause \fBmakewhatis\fR to exit at once, possibly in the middle of parsing or formatting a file. The output databases are corrupt and should be removed. .PD .SH "SEE ALSO" apropos(1), man(1), whatis(1), man.conf(5) .SH "HISTORY" A \fBmakewhatis\fR utility first appeared in 2BSD. It was rewritten in perl(1) for OpenBSD\ 2.7 and in C for OpenBSD\ 5.6. .PP The \fIdir\fR argument first appeared in NetBSD\ 1.0; the options \fB\-dpt\fR in OpenBSD\ 2.7; the option \fB\-u\fR in OpenBSD\ 3.4; and the options \fB\-aCDnQT\fR in OpenBSD\ 5.6. .SH "AUTHORS" Bill Joy wrote the original BSD \fBmakewhatis\fR in February 1979, Marc Espie started the Perl version in 2000, and the current version of \fBmakewhatis\fR was written by Kristaps Dzonsons <\fIkristaps@bsd.lv\fR> and Ingo Schwarze <\fIschwarze@openbsd.org\fR>.