Text formating

Alexander Dalloz alexander.dalloz at uni-bielefeld.de
Mon Apr 26 17:07:34 UTC 2004


Am Mo, den 26.04.2004 schrieb Bill Gradwohl um 18:00:

> >Mary had a little lamb, it's fleece was white as snow.
> >A quick brown fox jumps over the lazy dog.
> 
> That's almost what I want. I still want the 'A quick ...' line to continue
> after '... snow.' on the same line as in :
>  ... white as snow. A quick brown ...

Ah, ok, I thought you did want a line break when a combination of a dot
and line wrapping appears. So

$ cat testfile | tr -d '\n' | sed -e 's/\\n/ /g'
--> result:
Mary had a little lamb, it's fleece was white as snow. A quick brown fox
jumps over the lazy dog.

would fit your need.

> Your approach led me to the solution:
>    sed -e :a -e 'N;s/\n\([^\x0a]\)/ \1/;ta' infile >outfile

That line does not produce any output on my FC1.

> Thank You

> Bill Gradwohl

Alexander


-- 
Alexander Dalloz | Enger, Germany | GPG key 1024D/ED695653 1999-07-13
Fedora GNU/Linux Core 1 (Yarrow) on Athlon CPU kernel 2.4.22-1.2179.nptl
Sirendipity 19:04:48 up 8 days, 1:50, load average: 0.00, 0.01, 0.03 
                   [ Γνωθι σ'αυτον - gnothi seauton ]
             my life is a planetarium - and you are the stars
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20040426/dc29cbec/attachment-0001.sig>


More information about the fedora-list mailing list