(unless blocklist-func
(error "Customize `mh-junk-program' appropriately"))
(mh-iterate-on-range msg range
- (message "Blocklisting message %d..." msg)
- (funcall (symbol-function blocklist-func) msg)
- (message "Blocklisting message %d...done" msg))))
+ (funcall (symbol-function blocklist-func) msg))))
;;;###mh-autoload
(defun mh-junk-whitelist (range)
(unless allowlist-func
(error "Customize `mh-junk-program' appropriately"))
(mh-iterate-on-range msg range
- (message "Allowlisting message %d..." msg)
- (funcall (symbol-function allowlist-func) msg)
- (message "Allowlisting message %d...done" msg))))
+ (funcall (symbol-function allowlist-func) msg))))
\f
(let ((current-folder mh-current-folder)
(msg-file (mh-msg-filename msg mh-current-folder))
(sender))
- (message "Reporting message %d..." msg)
+ (message "Reporting message %d as spam with spamassassin..." msg)
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(with-current-buffer mh-log-buffer
(call-process mh-spamassassin-executable msg-file mh-junk-background nil
- ;; -R removes from allow-list
+ ;; -R removes from allowlist
"--report" "-R")
(when mh-sa-learn-executable
- (message "Recategorizing message %d as spam..." msg)
+ (message "Recategorizing message %d as spam with sa-learn..." msg)
(mh-truncate-log-buffer)
(call-process mh-sa-learn-executable msg-file mh-junk-background nil
"--spam" "--local" "--no-sync")))
(kill-buffer show-buffer))
(write-file msg-file)
(when mh-sa-learn-executable
- (message "Recategorizing message %d as ham..." msg)
+ (message "Recategorizing message %d as ham with sa-learn..." msg)
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(car (mh-funcall-if-exists
ietf-drums-parse-address (mh-get-header-field "From:"))))
(kill-buffer nil)
- (unless (or (null from) (equal from ""))
- (mh-spamassassin-add-rule "whitelist_from" from))
- (message "Allowlisting sender of message %d...done" msg))))
+ (if (or (null from) (equal from ""))
+ (message "Allowlisting sender of message %d...%s"
+ msg "not done (cannot identify sender)")
+ (mh-spamassassin-add-rule "whitelist_from" from)
+ (message "Allowlisting sender of message %d...done" msg)))))
(defun mh-spamassassin-add-rule (rule body)
"Add a new rule to \"~/.spamassassin/user_prefs\".
The \"Bogofilter tuning HOWTO\" describes how you can fine-tune Bogofilter."
(unless mh-bogofilter-executable
(error "Unable to find the bogofilter executable"))
+ (message "Blocklisting message %d with bogofilter..." msg)
(let ((msg-file (mh-msg-filename msg mh-current-folder)))
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(with-current-buffer mh-log-buffer
(call-process mh-bogofilter-executable msg-file mh-junk-background
- nil "-s"))))
+ nil "-s")
+ (message "Blocklisting message %d with bogofilter...done" msg))))
;;;###mh-autoload
(defun mh-bogofilter-allowlist (msg)
See `mh-bogofilter-blocklist' for more information."
(unless mh-bogofilter-executable
(error "Unable to find the bogofilter executable"))
+ (message "Allowlisting message %d with bogofilter..." msg)
(let ((msg-file (mh-msg-filename msg mh-current-folder)))
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(with-current-buffer mh-log-buffer
(call-process mh-bogofilter-executable msg-file mh-junk-background
- nil "-n"))))
+ nil "-n")
+ (message "Allowlisting message %d with bogofilter...done" msg))))
\f
update SpamProbe's training."
(unless mh-spamprobe-executable
(error "Unable to find the spamprobe executable"))
+ (message "Blocklisting message %d with spamprobe..." msg)
(let ((msg-file (mh-msg-filename msg mh-current-folder)))
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(with-current-buffer mh-log-buffer
(call-process mh-spamprobe-executable msg-file mh-junk-background
- nil "spam"))))
+ nil "spam")
+ (message "Blocklisting message %d with spamprobe...done" msg))))
;;;###mh-autoload
(defun mh-spamprobe-allowlist (msg)
See `mh-spamprobe-blocklist' for more information."
(unless mh-spamprobe-executable
(error "Unable to find the spamprobe executable"))
+ (message "Allowlisting message %d with spamprobe..." msg)
(let ((msg-file (mh-msg-filename msg mh-current-folder)))
(mh-truncate-log-buffer)
;; Put call-process output in log buffer if we are saving it
;; (this happens if mh-junk-background is t).
(with-current-buffer mh-log-buffer
(call-process mh-spamprobe-executable msg-file mh-junk-background
- nil "good"))))
+ nil "good")
+ (message "Allowlisting message %d with spamprobe...done" msg))))
(provide 'mh-junk)