Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
From: Thomas Mittelstaedt <tmstaedt@t-mittelstaedt.de>
Subject: Re: splitting on body
Date: 21 Aug 2003 23:53:48 +0200	[thread overview]
Message-ID: <86d6ey8yoj.fsf@nan.here> (raw)
In-Reply-To: <egada3qw1n.fsf@sefirot.ii.uib.no>

"Ketil Malde" <ketil+@ii.uib.no> writes:

> Hi,
> 
> I'm struggling to split messages based on body, using the example from
> the Info manual:
> 
>           (defun split-on-body ()
>             (save-excursion
>               (set-buffer " *nnmail incoming*")
>               (goto-char (point-min))
>               (when (re-search-forward "Some.*string" nil t)
>                 "string.group")))
> 

Why don't you use procmail to do split-on-body stuff?
Insert some header in the procmail process and then
use standard gnus splitting based on these special additional headers
or move that mail to a special file.
I, for instance, use a special header called X-SpamProbe to
filter for spam.
Here is the relevant part of my .procmailrc:

:0 wf 
SCORE=| spamprobe -8 receive
:0 wf
| formail -I "X-SpamProbe: $SCORE"
:0 a
*^X-SpamProbe: SPAM
spamprobe

Did this help?

-- 
Thomas Mittelstaedt
Thomas Mittelstaedt <tmstaedt@t-mittelstaedt.de>
   
   


       reply	other threads:[~2003-08-21 21:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <egada3qw1n.fsf@sefirot.ii.uib.no>
2003-08-21 21:53 ` Thomas Mittelstaedt [this message]
     [not found]   ` <egy8xmpa40.fsf@sefirot.ii.uib.no>
2003-08-22 10:36     ` Ted Zlatanov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86d6ey8yoj.fsf@nan.here \
    --to=tmstaedt@t-mittelstaedt.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).