Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (SunOS-4.1.3)
Apropos / Subsearch:
optional field

CAT(1V)                                                                CAT(1V)

       cat - concatenate and display

       cat [ - ] [ -benstuv ] [ filename...  ]

       /usr/5bin/cat [ - ] [ -estuv ] [ filename...  ]

       The  System  V  version  of this command is available with the System V
       software installation option.  Refer  to  for  information  on  how  to
       install optional software.

       cat  reads  each  filename  in sequence and displays it on the standard
       output.  Thus:

              example% cat goodies

       displays the contents of goodies on the standard output, and

              example% cat goodies1 goodies2 >> goodies3

       concatenates the first two files and places the result on the third.

       If no filename argument is given, or if the argument `-' is given,  cat
       reads  from  the  standard input.  If the standard input is a terminal,
       input is terminated by an EOF condition.

       -b     Number the lines, as -n, but omit the line  numbers  from  blank

       -e     Display  non-printing characters, as -v, and in addition display
              a $ character at the end of each line.

       -n     Precede each line output with its line number.

       -s     Substitute a single  blank  line  for  multiple  adjacent  blank

       -t     Display  non-printing characters, as -v, and in addition display
              TAB characters as ^I (CTRL-I).

       -u     Unbuffered.  If -u is not used, output is buffered in blocks, or
              line-buffered if standard output is a terminal.

       -v     Display  non-printing  characters (with the exception of TAB and
              NEWLINE characters) so that they are visible.   Control  charac-
              ters  print  like  ^X for CTRL-X; the DEL character (octal 0177)
              print as `^?'.  Non-ASCII characters (with the high bit set) are
              displayed as M-x where M- stands for `meta' and x is the charac-
              ter specified by the seven low order bits.

       -e     If the -v option is specified, display a $ character at the  end
              of each line.

       -s     Suppress messages about files which cannot be opened.

       -t     If  the  -v  option  is  specified, display TAB characters as ^I
              (CTRL-I) and FORMFEED characters as ^L (CTRL-L).

       -v     Display non-printing character (with the exception of TAB,  NEW-
              LINE, and FORMFEED characters) so that they are visible.

       The  environment  variables  LC_CTYPE, LANG, and LC_default control the
       character classification throughout cat.  On entry to cat, these  envi-
       ronment  variables  are checked in the following order: LC_CTYPE, LANG,
       and LC_default.  When a valid value  is  found,  remaining  environment
       variables for character classification are ignored.  For example, a new
       setting for LANG does not override the current valid character  classi-
       fication  rules  of  LC_CTYPE.   When  none of the values is valid, the
       shell character classification defaults to the POSIX.1 "C" locale.

       cp(1), ex(1), more(1), pg(1V), pr(1V), tail(1)

       Beware of `cat a b >> a' and `cat a b >>  b',  which  destroy  the  input
       files before reading them.

                                 19 July 1989                          CAT(1V)