Date: Tue, 24 Nov 2009 13:09:10 -0800 From: Gary Kline <kline@thought.org> To: Giorgos Keramidas <keramida@ceid.upatras.gr> Cc: FreeBSD Mailing List <freebsd-questions@FreeBSD.ORG>, Chris Cowart <ccowart@rescomp.berkeley.edu> Subject: Re: need a newline between paragraphs.... Message-ID: <20091124210909.GE54631@thought.org> In-Reply-To: <87638zn92p.fsf@kobe.laptop> References: <20091124002920.GA51110@thought.org> <20091124003652.GH11723@hal.rescomp.berkeley.edu> <20091124013934.GA51279@thought.org> <87638zn92p.fsf@kobe.laptop>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Nov 24, 2009 at 07:09:34PM +0200, Giorgos Keramidas wrote: > On Mon, 23 Nov 2009 17:39:35 -0800, Gary Kline <kline@thought.org> wrote: > > PS: is there any one-liner to add back one newline between paragraphs? > > Not an accurate one. > > You can *guess* when a line ends with a punctuation character > *and* it is shorter than some configurable wrapping column that > it is probably the end of a paragraph. But this is only a > heuristic guess and a pretty silly heuristic at that. > it's prob'ly bcse i'm older than zeus, but it seems that i once wrote a script or short c program that detected the end-of-paragraph. maybe somewhere in atom. anyway, karl vogel came to my rescue with a two-byte change to the print $fh "$_"; line. appending "$/" resolves the problem. print $fh "$_$/"; now i can point kttsd's reader at the entire [huge] file -- while i read along. or read each chapter individually. the way i wrote them -- Gary Kline kline@thought.org http://www.thought.org Public Service Unix http://jottings.thought.org http://transfinite.thought.org The 7.31a release of Jottings: http://jottings.thought.org/index.php
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20091124210909.GE54631>