paste
v0.0.28
paste [OPTIONS] [FILE]...
Write lines consisting of the sequentially corresponding lines from each
FILE
, separated by TAB
s, to standard output.
Options
--serial
,-s
-
paste one file at a time instead of in parallel
--delimiters=<LIST>
,-d <LIST>
-
reuse characters from LIST instead of TABs
--zero-terminated
,-z
-
line delimiter is NUL, not newline
Examples
Join all the lines into a single line, using TAB as delimiter:
paste -s {{path/to/file}}
Join all the lines into a single line, using the specified delimiter:
paste -s -d {{delimiter}} {{path/to/file}}
Merge two files side by side, each in its column, using TAB as delimiter:
paste {{path/to/file1}} {{path/to/file2}}
Merge two files side by side, each in its column, using the specified delimiter:
paste -d {{delimiter}} {{path/to/file1}} {{path/to/file2}}
Merge two files, with lines added alternatively:
paste -d '\n' {{path/to/file1}} {{path/to/file2}}
The examples are provided by the tldr-pages project under the CC BY 4.0 License.
Please note that, as uutils is a work in progress, some examples might fail.