Add multiple line into one in shell script linux -


I have a Linux with many lines called 1.txt and need to merge every three lines

in a row. I have mentioned the output given below and need to know how to do it

  [xxx @ c0040229 ~] $ cat 1.txt c0043726.xxx.xx 50G, 3.6G , 44g, 8%, / opt / dunes of 200, / opt / tibco / script c0043725.xxx.xx 50g, 9. 5g, 38g, 21%, / opt / dime 196 k / opt / tibco / script c0043724.xxx.xx 50g, 1.6g, 46g, 4%, / opt / tibbo2k, / opt / Tibco / Script  

must be

  c0043726.xxx.xx, 50G, 3.6G, 44G, 8%, / Opt / tibco, 200K, / opt / tibco / scripts c0043725.xxx.xx, 50G, 9.5G, 38G, 21%, / opt / tinkco, 196 k /, / opt / tibco / script c0043724.xxx.xx , 50G, 1.6G, 46G, 4%, / opt / tibco, 92K, / opt / tibco / script  

Can someone help me?

I think what you want with the paste command:

 < Code> cat 1.txt | Paste-D, '- - -  

Comments

Popular posts from this blog

Member with no value in F# -

java - Joda Time Interval Not returning what I expect -

c# - Showing a SelectedItem's Property -