split(1)
split --
split a file into pieces
Synopsis
split [-l line_count] [-a suf_length] [file [name]]
split -b n[k|m] [-a suf_length] [file [name]]
split [-line_count] [-a suf_length] [file [name]]
Description
split
reads
file
and writes
it in
n-line
pieces
(default 1000 lines)
onto
a set of output files.
The name of the first output file is
name
with
aa
appended, and so on
lexicographically,
up to
zz
(a maximum of 676 files).
The maximum length of
name
is 2 characters less than the maximum filename length
allowed by the file system.
See
statvfs(2).
If no output name is given,
x is default.
If no input file is given, or
if
-
is given in its stead,
then the standard input file is used.
The following options are recognized:
-l line_count-
Specify the number of lines in each resulting file piece. The line_count argument is an
unsigned decimal integer. The default is 1000. If the input does not end with a newline
character, the partial line will be included in the last output line.
-a suf_length-
Use suf_length letters to form the suffix portion of the filenames of the split file.
If -a is not specified, the default suffix length is two. If the sum of the name
operand and the suf_length option-argument would create a filename exceeding
[NAME_MAX] bytes, an error will result; split will exit with a diagnostic message
and no files will be created.
-b n-
Split a file into pieces n bytes in size.
-b nk-
Split a file into pieces n*1024 bytes in size.
-b nm-
Split a file into pieces n*1 048 576 bytes in size.
Files
/usr/lib/locale/locale/LC_MESSAGES/uxdfm-
language-specific message file (see LANG on
environ(5)).
References
bfs(1),
csplit(1),
statvfs(2)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004