If you want to be merge two line set to one, SED and AWK command can use for this.
For example create a file linuxfaq.txt and add below lines,
# vim linuxfaq.txt
First line
Second line
Third line
Fourth line
Now the output should look like,
# awk 'NR%2{printf $0" ";next;}1' sample.txt
First line Second line
Third line Fourth line
# sed 'N;s/\n/ /' sample.txt
First line Second line
Third line Fourth line
# paste -d " " - - < sample.txt
Multiple lines merge into one,
# cat sample.txt | xargs
Comments (0)