Need regex code for counting newsgroups

There was a thread some time ago on ways to kill postings with too many cross-posts. Some of these methods involved regular expressions, most likely counting commas in the newsgroups header. Can anyone provide a pointer to the thread, or related threads?

Thanks,

Joe Gwinn

Reply to
Joe Gwinn
Loading thread data ...

You can set that in Agent 6.0 in folder properties. Today, I've been using the Message-ID field for the new flock of bozos. When I see a message id containing "theremailer" or "dont-email.me", it's a pretty good bet for the bin.

Pete Keillor

Reply to
Pete Keillor

Except that I cannot use Agent, because there is no Mac version.

I am using Thoth under MacOS, and Thoth follows Perl's version of regex.

Joe Gwinn

Reply to
Joe Gwinn

Runs great under Crossover Office on Linux, others have reported the MAC version is just as good. Turning on a signature I normally use only in the Forte Agent beta group...

Reply to
William Bagwell

How are you doing that, Pete? I only see a Message-ID field in filtering emails, not Usenet posts.

Reply to
Larry Jaques

The way I do it is based on the commas in the "Newgsgroups: " header.

Two newgroups .*,.* Three newsgroups .*,.*,.* Four newsgroups .*,.*,.*,.*

Where: ".*" means any number of any characters. ',' means itself -- a plain old comma.

Exactly how you tell your newsreader to use those varies. I would do something like "-10" for each one of those, so two newsgroups would be -10, three would be -20, four (or more) would be -30, and set the auto-kill threshold to -15. (Three is too many in cross-posting.) I also use + scores on the "Subject: " header for the very few things which I want to see which are cross-posted, such as the "What Is It" weekly puzzle posting thread.

Enjoy, DoN.

Reply to
DoN. Nichols

The third link in google for terms newsgroup filter crosspost count looks like an r.c.m thread from 31 Aug 2011, subject = "Agent kill filter help please". See eg

You could also add a term for your specific newsreader.

Reply to
James Waldby

H key to show the headers, then make a new filter with the message id in the filter expression like below.

Message-ID: {googlegroups\.com}

The "\" is needed in front of the "." in the regular expression language so that it isn't interpreted as a wildcard.

Pete Keillor

Reply to
Pete Keillor

Aha! Peachy. I'll give that a try. Thanks. Maybe this will work for reference headers, too. If I can catch the orig. message (he's filtered in my reader) when he's being referred to, I can end the spam created when good folks (guilttripping Gunner, et al) reply to said spammers.

I've been asking Agent techs (Beck, Gold, Prince) for text (or more header) filtering for a decade now, to no avail.

Reply to
Larry Jaques

That's what I was trying to remember. I knew there was a simple, battle-tested solution. Thanks

I use Thoth, which uses the Perl regex engine PCRE .

Wonder if there is a direct way to count commas and kill if count exceeds some threshold.

I can also put the subject header test earlier in the processing, and terminate filter processing for the correct subject.

Joe Gwinn

Reply to
Joe Gwinn

I did do that and got flooded with suggestions that I use some other newsreader, but I was looking for actual regex code, because the reader I currently use (Thoth) does accept regex, so step one is to try that.

Hmm. Thoth is uncommon, so I didn't think to try that.

But I just tried it, using "thoth regex cross posting" (without quotes), and it yielded another regex expression "x-ref matches Regular Expression" from

and

Joe Gwinn

Reply to
Joe Gwinn

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.