DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

head(C)


head -- print the first few lines of a file

Syntax

head [ -n number ] [ file ... ]

head [ -count ] [ file ... ]

Description

The head filter prints the first number lines of each of the specified files. If no files are specified, head reads from the standard input. If no number is specified, then 10 lines are printed.

The -count option is equivalent to the -n option.

head understands -- as the option delimiter.

Exit values

head returns the following values:

0
successful completion

>0
an error occurred

See also

tail(C)

Standards conformance

head is conformant with:

ISO/IEC DIS 9945-2:1992, Information technology - Portable Operating System Interface (POSIX) - Part 2: Shell and Utilities (IEEE Std 1003.2-1992);
X/Open CAE Specification, Commands and Utilities, Issue 4, 1992.


© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 03 June 2005