Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ cut(1V) — RISC iX 1.2

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

paste(1V)

CUT(1V)  —  UNIX Programmer’s Manual

NAME

cut − display selected fields from each line of a file

SYNOPSIS

/usr/5bin/cut −clist [ filename ... ]
/usr/5bin/cut −flist [ −dchar ] [ −s ] [ filename ... ]

DESCRIPTION

Cut prints fields from each line of a file (standard input by default).  The fields are specified by list and may be of fixed length (character positions) or variable length (delimted by a character, usually TAB). 

OPTIONS

−clist Cut by character positions.  The list is a comma-separated list of character positions, with numbering starting at 1.  A hyphen may be used to indicate a range.  Thus the list: ‘-4,10,13-16,44-’ indicates columns 1 through 4, 10, 13 through 16 and columns 44 to the end of the line. 

−flist Cut by delimited fields.  The comma-separated list specifies the numbers of fields which are separated by a delimiter character.  Hyphens may again be used to specify ranges.  If there are no occurences of the delimiter character within a line, then the entire line is printed unless the −s option is specified. 

−s Suppress printing of lines with no occurences of the delimiter character. 

−dchar Set the delimiter character to char. 

SEE ALSO

paste(1V)

BUGS

Input lines may not be longer than 1023 characters. 

4th Berkeley Distribution

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026