Gnus development mailing list
 help / color / mirror / Atom feed
From: TSUCHIYA Masatoshi <tsuchiya@namazu.org>
Subject: recheck arguments for commands to display spamicity scores
Date: Sat, 01 May 2004 00:18:52 +0900	[thread overview]
Message-ID: <87isfhbijn.fsf@namazu.org> (raw)

Hi,

I have added an optional argument `recheck', to `spam-generic-score',
`spam-bogofilter-score' and `spam-spamassassin-score'.

This argument means that they recalcurate spamicity scores using the
current spam databases even if target articles have spamicity score
headers.  I think that this argument is useful to check whether spam
databases are updated properly.

And more, I'd like to propose the patch attached at the last of this
message, to change their default actions, because old spamicity scores
kept by headers must be less important than ones calculated using the
current updated database, when using spam detector based on headers,
including `spam-use-bogofilter-headers'.

Can I commit this change?

-- 
TSUCHIYA Masatoshi
\f
--- spam.el	30 Apr 2004 14:33:58 -0000	7.33
+++ spam.el	30 Apr 2004 15:17:48 -0000
@@ -799,15 +799,15 @@
 	(return)))
     (or score 0)))
 
-(defun spam-generic-score (&optional recheck)
+(defun spam-generic-score (&optional use-header)
   "Invoke whatever scoring method we can."
   (interactive "P")
   (cond
    ((or spam-use-spamassassin spam-use-spamassassin-headers)
-    (spam-spamassassin-score recheck))
+    (spam-spamassassin-score use-header))
    ((or spam-use-bsfilter spam-use-bsfilter-headers)
-    (spam-bsfilter-score recheck))
-   (t (spam-bogofilter-score recheck))))
+    (spam-bsfilter-score use-header))
+   (t (spam-bogofilter-score use-header))))
 
 ;;; Summary entry and exit processing.
 
@@ -2065,13 +2065,13 @@
 	  spam-split-group)))))
 
 ;; return something sensible if the score can't be determined
-(defun spam-bogofilter-score (&optional recheck)
+(defun spam-bogofilter-score (&optional use-header)
   "Get the Bogofilter spamicity score"
   (interactive "P")
   (save-window-excursion
     (gnus-summary-show-article t)
     (set-buffer gnus-article-buffer)
-    (let ((score (or (unless recheck
+    (let ((score (or (when use-header
 		       (spam-check-bogofilter-headers t))
 		     (spam-check-bogofilter t))))
       (gnus-summary-show-article)
@@ -2231,13 +2231,13 @@
 	(spam-check-spamassassin-headers score)))))
 
 ;; return something sensible if the score can't be determined
-(defun spam-spamassassin-score (&optional recheck)
+(defun spam-spamassassin-score (&optional use-header)
   "Get the SpamAssassin score"
   (interactive "P")
   (save-window-excursion
     (gnus-summary-show-article t)
     (set-buffer gnus-article-buffer)
-    (let ((score (or (unless recheck
+    (let ((score (or (when use-header
 		       (spam-check-spamassassin-headers t))
 		     (spam-check-spamassassin t))))
       (gnus-summary-show-article)
@@ -2302,13 +2302,13 @@
 	  spam-split-group)))))
 
 ;; return something sensible if the score can't be determined
-(defun spam-bsfilter-score (&optional recheck)
+(defun spam-bsfilter-score (&optional use-header)
   "Get the Bsfilter spamicity score"
   (interactive "P")
   (save-window-excursion
     (gnus-summary-show-article t)
     (set-buffer gnus-article-buffer)
-    (let ((score (or (unless recheck
+    (let ((score (or (when use-header
 		       (spam-check-bsfilter-headers t))
 		     (spam-check-bsfilter t))))
       (gnus-summary-show-article)



             reply	other threads:[~2004-04-30 15:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-30 15:18 TSUCHIYA Masatoshi [this message]
2004-05-14 19:28 ` 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=87isfhbijn.fsf@namazu.org \
    --to=tsuchiya@namazu.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).