SYNOPSIS
man [
man [
man
man
man
DESCRIPTION
The man command either displays online reference pages or searches for reference pages that have specified keywords associated with them.
Normally, man displays the reference page for each specified entry. To display only a reference page of a given type, specify type on the command line. type is a number representing which type of reference pages to search. Reference pages come in the following types:
1 Commands and Utilities 3 Functions 4 File Formats 5 Miscellaneous
To indicate an operating system specific version of the entry (if one exists) or to indicate an command specific to a given set of commands and/or functions, append one of the following letters to the specified type:
n for 8.1/2012R2/10/2016/2019/11/2022 t for Tcl
When output is sent to the terminal, man invokes a pager command to filter and display the reference pages. If MANPAGER is defined, it is used. If not, and if PAGER is defined, it is used. If neither is defined, man defaults to using the command more -A -s.
Options
-C filelist-
specifies a list of .idx files (corresponding to .chm files) to search instead of searching the files listed in MAN_CHM_INDEX.
-H -
launches the default web browser and displays the HTML version of the reference page. The reference page is found by searching each path listed in the MAN_HTM_PATHS environment variable (or indicated by the
-P option) for an entry matching entry and type that indicates which page in the corresponding .chm file to display. -h -
launches the HTML Help viewer and displays the HTML Help version of the reference page. The reference page is found by searching each .idx listed in the MAN_CHM_INDEX environment variable (or indicated by the
-C option) for an entry matching entry and type that indicates which page in the corresponding .chm file to display. -k -
searches a precomputed database of synopsis lines for information on keywords.
-M path-
searches the directories indicated by path for reference pages. If
-M is not specified, man uses the path specified in the MANPATH environment variable if it is set; otherwise man searches $ROOTDIR/etc. All reference pages are found by searching similarly structured file trees rooted at one or more places. See the FILES section for a description of the files and directories man should find in each directory that it searches. -P html_paths-
specifies a list of HTML paths to search instead of searching the paths listed in MAN_HTM_PATHS when looking for a HTML version of a reference page.
If this option is not specified and MAN_HTM_PATHS is not set, man searches $ROOTDIR/etc/htm by default. All reference pages are found by searching similarly structured file trees rooted at one or more places. See the FILES section for a description of the files and directories man should find in each directory that it searches.
-T filelist-
specifies a list of .idx files to search instead of searching the files listed in MAN_TXT_INDEX when looking for a text version of a reference page.
-w -
displays only the file name of the file containing the specified entry.
-x -
displays the files that man is searching as it tries to find the entry.
Search Rules
To find a given entry, man follows a set of search rules. When you specify a type, man searches for the appropriate page amongst pages of that type; otherwise, man looks for the first page named entry regardless of the type.
When the
When the
-
For each possible type (that is, type if you specified it, or all types in order from 1 through 9, then 0 if you did not),
man checks each directory in MAN_HTM_PATHS (or specified by
-P ) for a file named htmn/entry.n[l].html (or if that file is not found, htmn/entry.n[l].htm) where n is the type number, and l is the optional letter code. -
If still not found, man checks each directory in MAN_HTM_PATHS (or specified by
-P ) for a file named entry.html (or if that file is not found, entry.htm).
When neither
-
For each possible type (that is, type if you specified it, or all types in order from 1 through 9, then 0 if you did not):
-
man checks each directory in MANPATH for a file named catn/entry.n[l] where n is the type number, and l is the optional letter code. If it exists, man checks to see if it was compressed with pack, compress or mkszip, and uncompresses it (calling pcat if the file was packed).
-
man checks each directory in MANPATH for a file named mann/entry.n[l].
-
-
man checks each directory in MANPATH for a file named man.dbz. If it exists, man looks for the requested entry in its index (see man.dbz File Format).
-
man searches the .idx files listed in the MAN_TXT_INDEX environment variable for an entry matching the request entry which indicates the text (.txt) reference page to display.
man.dbz File Format
Sometimes, the reference pages are kept in a single large file, called man.dbz. The file starts with a magic text string:
!<man database compressed>\n
and continues with the index:
14 bytes formatted reference page name 9 bytes seek pointer 9 bytes length
The name is simply the page name, followed by a dot and the type number. For example, this reference page would be named man.1. When man finds a matching entry, it seeks to the point in the file specified by the given seek pointer, and uncompresses for length bytes. Each reference page is compressed separately.
EXAMPLES
To find the utilities that do comparisons, type:
man -k compar
ENVIRONMENT VARIABLES
- MAN_CHM_INDEX
-
contains a semicolon separated list of .idx files to search for entry when the
-h is specified. - MAN_TXT_INDEX
-
contains a semicolon separated list of .idx files to search for entry when the
-h is not specified. - MAN_HTM_PATHS
-
contains a semicolon separated list of .idx paths to search for entry when the
-H is specified. - MANPATH
-
contains a semicolon separated list of paths to search for reference pages.
- MANPAGER, PAGER
-
contains an output filtering command for use when displaying reference pages on a terminal.
- TMPDIR
-
identifies the directory where temporary files reside.
FILES
- $ROOTDIR/etc
-
is the default directory for the online reference pages. The rest of the files listed here reside in this directory.
- cat[0-9]/*.[0-9]
-
pre-formatted reference pages in normal, compressed, or packed form.
- htm/htm[0-9]/*.[0-9]
-
HTML reference pages.
- man[0-9]/*.[0-9]
-
unformatted reference pages.
- Note:
-
Unformated reference pages are not currently supported. Reference pages stored in these directories are treated as pre-formatted pages.
- whatis
-
is a database used by
-k option. - *.chm
- chm/*.chm
-
HTML Help files containing collections of reference pages complete with index, table of contents, and full text search.
- *.idx
- chm/*.idx
-
index files that man how to find HTML Help and text versions of individual reference files. The .idx files to search are indicated by the MAN_CHM_INDEX and MAN_TXT_INDEX environment variables.
- man.dbz
-
is a master file containing all reference pages.
The etc directory is found using the ROOTDIR environment variable.
DIAGNOSTICS
Possible exit status values are:
PORTABILITY
POSIX.2. x/OPEN Portability Guide 4.0. All UNIX systems. Windows 8.1. Windows Server 2012 R2. Windows 10. Windows Server 2016. Windows Server 2019. Windows 11. Windows Server 2022.
The
AVAILABILITY
PTC MKS Toolkit for Power Users
PTC MKS Toolkit for System Administrators
PTC MKS Toolkit for Developers
PTC MKS Toolkit for Interoperability
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
PTC Windchill Requirements and Validation
SEE ALSO
PTC MKS Toolkit 10.4 Documentation Build 39.