SYNOPSIS

       cut -b list [-n] [file . . . ]
       cut -c list [file . . . ]
       cut -f list [-d char] [-s] [file . . . ]


DESCRIPTION

       The  cut  utility selects columns of files for printing based either on
       byte position, character position, or field delimiters.

       If no file is given, or if file is -, cut reads from standard input.

       The list consists of numbers separated by commas or blanks that  select
       the  corresponding input field, starting at 1.  Ranges of fields may be
       given as in

       m-n    Selects all fields from m to n.

       m-     Selects all fields from m to the last field of each input  line.

       -n     Selects all fields from the first field to n.

       The cut command accepts the following options:

       -c list
              Each  character  of  an input line forms a column.  All selected
              characters are printed without intervening separators; all  new-
              line characters of the input file are passed through.

       -d char
              Sets the field delimiter character for the -f option to char.

       -f list
              Columns  are sequences of zero or more characters separated by a
              field delimiter character, by default  a  tabulator  (\t).   The
              selected  fields  are  printed, separated by the field delimiter
              character.  Lines that do not contain the field delimiter  char-
              acter are passed through unchanged.

       -s     With  the  -f option, lines that do not contain the field delim-
              iter character are not passed through.

       The following options were introduced by POSIX.2:

       -b list
              Each single byte of an input line forms a column.  All  selected
              bytes  are  printed  without intervening separators; all newline
              characters of the input file are passed through.

       -n     Changes the behavior of the -b option such that ranges start and
              end at character boundaries.


ENVIRONMENT VARIABLES

       iters, it is not generally usable to select fields of white-space sepa-
       rated tables.  Use awk(1) for this purpose.



Heirloom Toolchest                  12/6/04                             CUT(1)

Man(1) output converted with man2html