[ILUG] newline in regex / sed

From: Paul Jakma (paulj at domain itg.ie)
Date: Fri 21 Jul 2000 - 17:54:44 IST


how do i represent a newline in sed?

i want to do:

sed -e 's/^acme\[\(.*\)\]\(.*\)/whatever\[\1\]NEWLINEacme\[\1\]\2/

ie i want to insert a line before a specific line, using something i
matched on that specific line to create the insert line...

but i just can't seem to find something to the NEWLINE part. not \^M,
\<newline>, nothing...

any ideas?

--paulj



This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:06:57 GMT