paste
paste [options] filesMerge corresponding lines of one or more files into tab-separated vertical columns. Use - to read from standard input, instead of specifying a file. See also cut, join, and pr.
Options
-dchar, --delimiters=charSeparate columns with char instead of a tab. You can separate columns with different characters by supplying more than one char.
--help
Print a help message and then exit.
-s, --serial
Merge lines from one file at a time.
--version
Print version information and then exit.
Examples
Create a three-column file from files x, y, and z:paste x y z > file
List users in two columns:
who | paste - -
Merge each pair of lines into one line:
paste -s -d"\t\n" list
0 comments:
Post a Comment