John Doe wrote:
$ cat $FILE | tr "\n" " " | sed 's/ *></>\n</g'
I was yearning for someone to chime with that! sed is clearly the best & most straightforward way to do this task.
I can't help myself - there's a "useless use of cat":
$ < $FILE tr "\n" " " | sed 's/ *></>\n</g'
http://www.partmaps.org/era/unix/award.html#uucaletter