On 24 Dec 2019, Michael Dukelsky said the following...
MD> DR> I'm thinking a script that will take the Desc line, and create
MD> DR> multiple LDesc lines within the tic file before it gets processed
MD> DR> would be the best way to work around this...
MD>
MD> Maybe it is possible to ask the sysop who hatches files with a long Desc
MD> line to hatch with short Ldesk lines instead of it?
It might be possible, but this gave me an excuse to work on my bash
scripting... ;)
Now to see if it works on the production system. Do you know if the tic file
needs to have the Desc line, or can it just have multiple LDesc lines?
Here's what I've got for a script:
#!/bin/bash
ticlength=""
cd ~/mystic/echomail/in/
for filename in ~/mystic/echomail/in/*.tic; do
[ -e "$filename" ] || continue
ticlength=`cat "$filename" | grep "^Desc " | wc -c`
if [ $ticlength -gt 45 ]
then
sed -i 's/^Desc/LDesc/g' $filename
fmt -w 45 -p LDesc $filename > test.tic
cp test.tic $filename
rm test.tic
fi
done
---
Black Panther(RCS)
Castle Rock BBS
--- Mystic BBS v1.12 A43 2019/03/02 (Linux/64)
* Origin: Castle Rock BBS - bbs.castlerockbbs.com (1:317/3)
|