Output the contents of a terminfo capability file (UNIX)


infocmp [-1CcdeFfIiLlnprTuV] [-R subset] [-s [d|i|l|c] [-v number]
        [-w width] [terminal_name]

Runs on:

QNX Neutrino


("one") Force the output to contain one entry per line. Without this option, output is printed to a maximum width of 60 characters, each line containing as many entries as can fit on that line.
Generate output in termcap format.
List common capabilities.
List different capabilities.
Format output as a C initializer.
Compare terminfo files.
With -1, format complex strings.
Generate output in terminfo format. This option is the default.
Analyze initialization/reset.
Use the long C variable names listed in /usr/include/term.h
Output terminfo names.
List capabilities in neither.
Ignore padding specifiers.
-R subset
Restrict the output to a given subset. This option is for use with archaic versions of terminfo like those on SVr1, Ultrix, or HP/UX that don't support the full set of SVR4/XSI Curses terminfo, and variants such as AIX that have their own extensions incompatible with SVr4/XSI. Available terminfo subsets are SVr1, Ultrix, HP, and AIX. You can also choose the subset BSD, which selects only capabilities with termcap equivalents recognized by 4.4BSD.
With -C, output in termcap form.
-s [d|i|l|c]
Sort the fields within each type according to the argument:
  • d — leave fields in the order that they're stored in the terminfo database
  • i — sort by terminfo name
  • l — sort by the long C variable name
  • c — sort by the termcap name

If you don't specify the -s option, the fields are sorted alphabetically by the terminfo name within each type, except in the case of the -C or the -L options, which cause the sorting to be done by the termcap name or the long C variable name, respectively.

Eliminate size restrictions on the generated text.
Produce source with use=.
Print the version number, and then exit.
-v number
Be verbose.
-w width
Force the output to the specified number of columns. As many entries as fit on each line are output.
The name of a terminal capability file to display. If the TERMINFO environment variable is not set, the file is read from the /usr/lib/terminfo directory in a subdirectory named by the first letter of the terminal name. For example, the VT100 terminfo file is stored in /usr/lib/terminfo/v/vt100. If set, the TERMINFO environment variable defines a directory where the compiled description file is read from. If a terminal_name isn't specified, the terminal named in the TERM environment variable is used.


The infocmp utility is used to output the contents of a previously compiled terminfo capability file in a number of formats. The default format is suitable for editing and recompilation with the tic utility. The output is sorted such that the Boolean capabilities are output first, followed by the integer capabilities and then the string fields. The infocmp utility, executed without any options, produces the terminfo description of the currently defined terminal in a form suitable for editing and recompilation with the tic utility.

If no options are specified and zero or one terminal name is specified, the -I option is assumed.

For more information, see Strang, John, Linda Mui, and Tim O'Reilly. 1988. termcap & terminfo. Sebastopol, CA: O'Reilly and Associates. ISBN 0937175226.