🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #32928

Re: trn: Want to KILL-file (globally) articles on regexp: !/[a-z]/

#32928
From: Mark Brader
Date: Sun, 20 Apr 1997 00:00
28 lines
1629 bytes
Jeremy Mathers:
> I have found that spammers like to put their subjects IN ALL UPPERCASE
> LIKE THIS. ... [I would like to try]
> 	!/[a-z]/c:j
> However, AFAIK, the above syntax isn't valid trn
> KILLFILE syntax.  That is, there seems to be no negation operator.

Search for subject lines that don't have a lower case letter anywhere
after the initial "Subject: " or "Subject: Re: " prefix.  That is:

	/^Subject[: Re]*[^a-z]*$/c:j

Yes, you need "Subject" in there explicitly.  That's because trn does
its match against the whole line (at least, trn 3.6 does), and you need
to anchor the match at both ends to be sure that the [^a-z] test is
applied to the relevant characters.

[: Re]* is a little too broad, but this is unlikely to matter in practice.

(Posted and emailed.)
-- 
Mark Brader, msb@sq.com         sed -e "s;??\\([-=(/)'<!>]\\);?\\\\?\\1;g"
SoftQuad Inc., Toronto          will fix them...        -- Karl Heuer

My text in this article is in the public domain.

Technical Details
Message-ID: <1997Apr20.041803.10990@sq.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mail
References: <E8wB97.J7o@midway.uchicago.edu>

Show Full Headers
Complete Article Headers
Message-ID: <1997Apr20.041803.10990@sq.com>
Subject: Re: trn: Want to KILL-file (globally) articles on regexp: !/[a-z]/
Date: Sun, 20 Apr 1997 00:00:00 +0000
From: msb@sq.com (Mark Brader)
References: <E8wB97.J7o@midway.uchicago.edu>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mail
X-Deja-AN: 236099073
Organization: SoftQuad Inc., Toronto, Canada
Newsgroups: news.software.readers
Summary: /^Subject[: Re]*[^a-z]*$/c: j