[SLUG] sed

From: Eben King (eben01@verizon.net)
Date: Wed Jun 02 2010 - 22:23:20 EDT


I'm pretty good at regexes, but programming in sed is where I break down.
How does one convert this:

A1
B1
A2
B2
A3
B3
...

into this:

A1 B1
A2 B2
A3 B3
...

? I tried "sed -n -e :begin -e H -e H -e p" but apparently the "pattern
space" referred to in the man page includes the LF. The goal is not only to
get it done right, but to get it done _fast_.

-- 
-eben    QebWenE01R@vTerYizUonI.nOetP    royalty.mine.nu:81
Answer: two spoonfuls in my cup, please.
Question: how much should I use?      (why top-posting is bad)
     http://www.fscked.co.uk/writing/top-posting-cuss.html
-----------------------------------------------------------------------
This list is provided as an unmoderated internet service by Networked
Knowledge Systems (NKS).  Views and opinions expressed in messages
posted are those of the author and do not necessarily reflect the
official policy or position of NKS or any of its employees.



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 15:45:45 EDT