my take is that bash tools along with AWK will be much better placed to do the job. You can sort and redirect the output to a file thus ensuring that the primary source remains intact.
On Thu, Jun 13, 2013 at 1:04 PM, Tony Likhanga <tlikhanga@gmail.com> wrote:Otherwise, sed may have some pretty neat solution if you dig deeper.3. Make an intelligent estimation of the number of lines contained in between the start & end entries.2. Identify the exact end of the records you want to filter out1. Identify the exact start of the records you want to filter outOn a linux box, grep -A piped into grep -B with the output redirected into a new file always sorts me out. (Probably egrep works the same on other platforms)The trick is :
_______________________________________________
skunkworks mailing list
skunkworks@lists.my.co.ke
------------
List info, subscribe/unsubscribe
http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks
------------
Skunkworks Rules
http://my.co.ke/phpbb/viewtopic.php?f=24&t=94
------------
Other services @ http://my.co.ke
_______________________________________________
skunkworks mailing list
skunkworks@lists.my.co.ke
------------
List info, subscribe/unsubscribe
http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks
------------
Skunkworks Rules
http://my.co.ke/phpbb/viewtopic.php?f=24&t=94
------------
Other services @ http://my.co.ke