1 |
On Friday 6 March 2009, 00:01, Adam Carter wrote: |
2 |
> > > awk '/^foo/,/^bar/' a |
3 |
> > > |
4 |
> > > does the same :) |
5 |
> > |
6 |
> > Nice... |
7 |
> |
8 |
> Thanks for all these answers. Interesingly when I moved the sed script |
9 |
> (sed "s/;/\\n/g") from Linux to Solaris it failed as Solaris sed |
10 |
> doesn't like putting the newline character as the "translated to" bit. |
11 |
> Installing GNU sed on the Solaris box sorted that out. |
12 |
|
13 |
Or for the future, with seds that do not like \n in the rhs, you can do |
14 |
|
15 |
sed 's/;/\ |
16 |
/g' |