TIP: Click on subject to list as thread! ANSI
echo: batpower
to: Mark Lewis
from: Richard Webb
date: 2008-12-31 05:47:18
subject: how would you approach this?

Hi Mark,

On Tue 2036-Dec-30 21:41, Mark Lewis (1:3634/12) wrote to Paul Quinn:

ML> the only thing i'm aware of that he may have a problem with is
ML> "spurious" lines that may appear in the message body before the
ML> actual test he is interested in... at least one of my packages seems
ML> to have a slight (buffering?) problem with long lines and sometimes
ML> the extraneous text ends up in the first line or two of the gated
ML> message's body... i saw on, the other day, where the date field go
ML> cut and the first line was "on, dec 29, 2008" for
example... "on"
ML> was the completion of the "Date: Mon" control line...

sOlved that.  wE grab from line 9 to end of message using
sed to a temporary file.  fIrst line has

"NN2NN Winlink Post" email address deleted
THE callsign will be the actual call sign of submitter,
amateur radio callsign that is.
But, "WInlink" will actually occur.

sO we use ms dos find command to get the line number where
"Winlink" occurs, use a search replace util to strip the
parentheses leaving line number standing alone.
sInce the original batch that does this is invoked from a
shell out of netmgr we can't use nset to get the variable,
but we can use HOrst's listmod to get that line number
stuffed as an environment var into the batch we're creating. THis batch
then makes another temporary file, with line 1
being the line with "Winlink" in the text.  WE then can pull
lines 2-10 out, having the basic data we want.  IF a certain keyword is
contained on line 11, then we process the
remaining lines in the file.

Btw, lines 2-10 are output to a file, the carriage returns
replaced with spaces, (ascii 32) and then put two or three
places.

AS you can tell, a rather rube GOldberg method to get to
where we want to go, but we've got our starting line which
gives us a place to work from.  THE main file which is
message in full is exported to another location for backup,
other temporary files we created with sed deleted.

ML> i've gone into my configs and set the "kill" on some of the longer
ML> control lines but i don't know if that will/can actually handle the
ML> spurious lines problem that richard may be running into...

tHink I've got it all solved.

ML> it would be nice if the messages he received contained a "start
ML> here" type line so that his stuff could simply toss out everything
ML> above there and possibly even a "stop here" line so that everything
ML> below was also tossed out... however, i think that's something that
ML> he'd have to take up with the guy on the other end maintaining the
ML> input form stuff... 

"End here" or stop here seems to be the standard fidonet
tear line we're all used to .
I replace them when processing done with a pair of $
characters.
OTher manipulative stuff, too lengthy to describe.

HOpe htat clears it up.


Regards,
           Richard
--- timEd 1.10.y2k+
* Origin: Radio REscue net operations BBS (1:116/901)
SEEN-BY: 10/1 3 34/999 90/1 120/228 123/500 140/1 222/2 226/0 249/303 250/306
SEEN-BY: 261/20 38 100 1404 1406 1410 1418 266/1413 280/1027 320/119 393/68
SEEN-BY: 396/45 633/104 260 267 285 640/954 690/682 734 712/0 104 313 848
SEEN-BY: 800/432 801/161 189 2222/700 2320/100 105 200 2905/0
@PATH: 116/901 3634/12 123/500 261/38 633/260 712/848 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.