Quantcast
Channel: How to achieve side by side output in Bash? - Super User
Browsing latest articles
Browse All 5 View Live

Answer by gidds for How to achieve side by side output in Bash?

One approach is to avoid printing the newline after all but the last field on each line.  (Especially if you have lines with different numbers of fields.)Some platforms can do this in the echo command...

View Article



Answer by Kamil Maciorowski for How to achieve side by side output in Bash?

A portable tool for this is paste:( echo A echo a echo B echo b echo C echo c echo D echo d) | paste - -From the specification:The default operation of paste shall concatenate the corresponding lines...

View Article

Answer by choroba for How to achieve side by side output in Bash?

You can use fmt to format the output:( echo A echo a echo B echo b echo C echo c echo D echo d) | fmt -w 4

View Article

How to achieve side by side output in Bash?

I have a script, let's say it's this (obviously, my real one is much more complicated):echo Aecho aecho Becho becho Cecho cecho Decho dIs there an easy way to have the lines side by side?A aB bC cD dOr...

View Article

Answer by Peter - Reinstate Monica for How to achieve side by side output in...

Let's assume here that your sequence of echo commands is just an illustration that produces lines of text which in real life are coming from, say, an application; so that simply saying echo -n every...

View Article

Browsing latest articles
Browse All 5 View Live




Latest Images