Great Circle Associates List-Managers
(July 1994)
 

Indexed By Date: [Previous] [Next] Indexed By Thread: [Previous] [Next]

Subject: Re: Looking for useful shell scripts etc
From: Rich Zellich <zellich @ STL-17SIMA . ARMY . MIL>
Date: Fri, 15 Jul 94 8:45:04 CDT
To: List-Managers-Digest @ GreatCircle . COM

There's something wrong with your network mail-transmission software if
it truncates a message on a single "." (or causes the receiver to do so).

The standard is for the mail-sender to prepend any line starting with a
period with another period - i.e., change:
.ANY-OR-NO-TEXT<EOL>
to:
..ANY-OR-NO-TEXT<EOL>
and for the mail receiver to strip off any leading period.

You shouldn't have to do it yourself...


Given that you *do* have the problem, though, there are better ways of
handling it.  The one I think preferable is to run "fill" against your
input files before digestifying it.  "fill" is a utility that will fold
all your lines to a standard length (with some amount of smarts about
what constitutes a paragraph and when leading spaces should be retained
on lines) - it will break on word boundaries, rather than in the middle
of a text string.  The only drawback is that it might not handle some
specially-formatted text correctly - tables, cute signature lines, etc.,
might not work right.  The overall simplest method is probably what
you're doing, followed by the sed script "/^\.$/d" which will delete any
line consisting only of a period - or use "s/^\.$/ \<CTL-H>./" to change
it to <SPACE><BackSpace><PERIOD> (neater than doing <SPACE><PERIOD>).


Cheers,
Rich

Indexed By Date Previous: Re: Looking for useful shell scripts etc
From: Michelle Dick <artemis @ rahul . net>
Next: Re: Hard-coded '-approval'
From: Jared_Rhine @ hmc . edu
Indexed By Thread Previous: Re: Looking for useful shell scripts etc
From: Michelle Dick <artemis @ rahul . net>
Next: Re: Hard-coded '-approval'
From: Jared_Rhine @ hmc . edu

Google
 
Search Internet Search www.greatcircle.com