Differences between revisions 2 and 3
Revision 2 as of 2002-05-28 12:01:50
Size: 364
Editor: SimonHuggins
Comment:
Revision 3 as of 2005-03-15 08:06:12
Size: 694
Editor: ccs1
Comment:
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
CategoryComputingTips > SedCompTips CategoryComputingTips > SedCompTips
Line 20: Line 20:
   [http://www.andrewsaluk.com empire poker] - empire poker online poker texas holdem |
[http://www.andrewsaluk.com texas holdem] - texas holdem poker online poker |
[http://www.andrewsaluk.com online poker] - texas holdem poker online poker |
[http://www.andrewsaluk.com poker] - texas holdem online poker empire poker |

CategoryComputingTips > SedCompTips

Sed Tips

Insert a newline with sed

You have to escape the newline itself. Putting \n in the replacement side just won't work but you probably found that out already :)

sed -e 's/foo/f\
o/'
foo
f
o

Perl can do the same thing with perl -pe 's/foo/f\no/'

[http://www.andrewsaluk.com texas holdem] - texas holdem poker online poker | [http://www.andrewsaluk.com online poker] - texas holdem poker online poker | [http://www.andrewsaluk.com poker] - texas holdem online poker empire poker |

TheEarthWiki: SedCompTips (last edited 2008-02-19 15:39:23 by localhost)