[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: help - how to get trnkill to work with trn 4.0




 > From: http://www.cas.org/~lvirden (Larry W. Virden)
 > Date: Fri  Oct 25,  1:56pm
 >
 > 
 > I have not yet gotten this figured out - thanks for any help you might
 > provide.
 > 
 > -- 
 > :s Larry W. Virden                 INET: http://www.cas.org/~lvirden
 > :s <URL:http://www.teraform.com/%7Elvirden/> <*> O- "We are all Kosh."
 > :s Unless explicitly stated to the contrary, nothing in this posting should
 > :s be construed as representing my employer's opinions.

This works for me.  Note that I've customized it a little -- it searches for
"search_string" and then saves each of those.

Sorry if this is too specialized for you or not too useful to you.

I should note that I only sequence through a _single_ .newsrc.  This is
also kinda klunky because it doesn't make use of the "E" command when it
really could/should.

Sorry if this doesn't solve your problems.

---
          >> Copulate but don't procreate. <<
          >> Vasectomy prevents abortion. <<

-------------------------------------------------------------------------------

#!/bin/sh
# trnkill - shell script to apply trn KILL files in the background
# 14 Mar 89  created for rn by Jim Olsen <http://www.XN.LL.MIT.EDU/~olsen>
# 10 Sep 93  modified for trn 3 (or 2) by Wayne Davison <http://www.borland.com/~davison>
# 16 Nov 94  complete rewrite; via e-mail from Chin Huang <http://www.io.sys/~cthuang>
#
# Options: -d   debug mode -- you see all gory action as it happens.
#
# Visit all newsgroups (if trn asks about anything else, just say no)
export TRNMACRO RNMACRO
TRNINIT='-q -s -T -t -x +X'
#export TRNINIT
TRNMACRO=$TRASHDIR/trnkill$$
# support for trn 2.x
RNMACRO=$TRNMACRO
DOTDIR=$HOME
export DOTDIR
trap '/bin/rm -f $TRNMACRO; exit' 1 2 3 15
cat >$TRNMACRO <<'EOF'
y  %(%m=n?+X^(z^):q)^(y^)
z  %(%m=[pa]?+\:-^J/search_string/a+^JX^(x^):)
x  %(%m=[pa]?m+\:s^J\:-^JX:)
^m 
^j 
EOF
if test X$1 = X-d; then
        echo y | trn $TRNINIT
else
        echo y | trn $TRNINIT >/dev/null 2>&1
fi
rm -f $TRNMACRO
exit 0



Why do you want this page removed?