From: James Cloos <cloos@jhcloos.com>
To: ding@gnus.org
Subject: Training dspam
Date: Sat, 29 Mar 2008 16:38:03 -0400 [thread overview]
Message-ID: <m38x019sfx.fsf@lugabout.jhcloos.org> (raw)
The manual suggests a couple of (defun)s to report erroneously collated
spam and innocent mail. The synchronous nature of the recommended
functions has proven painfully slow to use on my aging laptop, so I came
up with these modified (defun)s.
Perhaps they will be useful to someone else.
(defun gnus-summary-dspam-report-spam ()
"Submit spam to dspam, then mark it as expirable."
(interactive)
(gnus-summary-show-raw-article)
(gnus-eval-in-buffer-window gnus-article-buffer
(save-restriction
(widen)
(call-process-region (point-min) (point-max) "/usr/bin/dspam"
nil 0 nil "--mode=teft" "--user" (getenv "USER")
"--class=spam" "--source=error")))
(gnus-summary-mark-as-expirable 1))
(defun gnus-summary-dspam-report-innocent ()
"Submit false-positive to dspam."
(interactive)
(gnus-summary-show-raw-article)
(gnus-eval-in-buffer-window gnus-article-buffer
(save-restriction
(widen)
(call-process-region (point-min) (point-max) "/usr/bin/dspam"
nil 0 nil "--mode=teft" "--user" (getenv "USER")
"--class=innocent" "--source=error"))))
-JimC
--
James Cloos <cloos@jhcloos.com> OpenPGP: 1024D/ED7DAEA6
next reply other threads:[~2008-03-29 20:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-29 20:38 James Cloos [this message]
2008-03-31 14:16 ` Ted Zlatanov
2008-03-31 14:42 ` James Cloos
2008-03-31 19:58 ` Reiner Steib
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=m38x019sfx.fsf@lugabout.jhcloos.org \
--to=cloos@jhcloos.com \
--cc=ding@gnus.org \
/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).