View Single Post
Old 11-07-2006, 02:51 AM   #11
Antartica
Evangelist
Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.
 
Antartica's Avatar
 
Posts: 423
Karma: 1517132
Join Date: Jun 2006
Location: Madrid, Spain
Device: quaderno, remarkable2, yotaphone2, prs950, iliad, onhandpc, newton
Quote:
Originally Posted by valkyriesound
There must be an easy way of getting rid of this look in the text:

"street torches as well as the somewhat brighter light of the moon.
Sham knelt
where she was, watching the dark mansion intently for movement that might
indicate someone was inside."
Again with sed, if that text is in mytext.txt:

C:\> sed ":start;/[a-zA-Z] *\$/{N;s/ *\n/ /g;b start;}" mytext.txt > result.txt

That joins the lines that end with an alphabetical character with the next one.

NOTE: it's the first time that I use flow control in sed. Nice :-). I used the following manual to construct that command:
http://www.grymoire.com/Unix/Sed.html
Antartica is offline   Reply With Quote