Difference between revisions of "Paste"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | Merge every two lines: <code>cat /path/tofile.txt | paste -d " " - -</code><ref>https://stackoverflow.com/a/9605450</ref> | + | Merge every two lines: |
+ | * <code>cat /path/tofile.txt | paste -d " " - -</code><ref>https://stackoverflow.com/a/9605450</ref> | ||
+ | * <code>cat /path/tofile.txt | xargs -n2 -d'\n'<code> | ||
Revision as of 11:56, 29 December 2019
Merge every two lines:
cat /path/tofile.txt | paste -d " " - -
[1]cat /path/tofile.txt | xargs -n2 -d'\n'
See also
↑ https://stackoverflow.com/a/9605450
Advertising: