+2004-02-03 Reiner Steib <Reiner.Steib@gmx.de>
+
+ * spam.el (spam-directory): Derive from `gnus-directory'.
+
+ * spam-report.el (spam-report-url-to-file)
+ (spam-report-requests-file): New function and variable for offline
+ reporting.
+ (spam-report-url-ping-function): Add `spam-report-url-to-file'
+ and user defined function.
+ (spam-report-url-ping-mm-url): Remove doubled slash.
+
+2004-02-03 Teodor Zlatanov <tzz@lifelogs.com>
+
+ * spam.el (spam-list-of-processors): fixed spamassassin variable names
+
2004-02-03 Jesper Harder <harder@ifa.au.dk>
+ * spam.el (spam-check-spamoracle, spam-spamoracle-learn): Fix
+ format string mismatch.
+
+ * sieve.el (sieve-deactivate-all): do.
+
+ * nnfolder.el (nnfolder-request-set-mark, nnfolder-save-marks): do.
+
+ * nnlistserv.el (nnlistserv-kk-wash-article): do.
+
+ * nnml.el (nnml-request-set-mark, nnml-save-marks): do.
+
* mm-bodies.el (mm-7bit-chars): Don't include \r.
2004-02-02 Teodor Zlatanov <tzz@lifelogs.com>
(let ((range (nth 0 action))
(what (nth 1 action))
(marks (nth 2 action)))
- (assert (or (eq what 'add) (eq what 'del)) t
+ (assert (or (eq what 'add) (eq what 'del)) nil
"Unknown request-set-mark action: %s" what)
(dolist (mark marks)
(setq nnfolder-marks (gnus-update-alist-soft
nnfolder-marks-modtime))
(error (or (gnus-yes-or-no-p
(format "Could not write to %s (%s). Continue? " file err))
- (error "Cannot write to %s (%s)" err))))))
+ (error "Cannot write to %s (%s)" file err))))))
(defun nnfolder-open-marks (group server)
(let ((file (nnfolder-group-marks-pathname group)))
(mm-url-decode-entities)
(while headers
(goto-char (point-min))
- (re-search-forward (format "<!-- %s=\"\\([^\"]+\\)" (car headers) nil t))
+ (re-search-forward (format "<!-- %s=\"\\([^\"]+\\)" (car headers)) nil t)
(set (pop headers) (match-string 1)))
(goto-char (point-min))
(search-forward "<!-- body" nil t)
(let ((range (nth 0 action))
(what (nth 1 action))
(marks (nth 2 action)))
- (assert (or (eq what 'add) (eq what 'del)) t
+ (assert (or (eq what 'add) (eq what 'del)) nil
"Unknown request-set-mark action: %s" what)
(dolist (mark marks)
(setq nnml-marks (gnus-update-alist-soft
nnml-marks-modtime))
(error (or (gnus-yes-or-no-p
(format "Could not write to %s (%s). Continue? " file err))
- (error "Cannot write to %s (%s)" err))))))
+ (error "Cannot write to %s (%s)" file err))))))
(defun nnml-open-marks (group server)
(let ((file (expand-file-name
(sieve-refresh-scriptlist)
(if (sieve-manage-ok-p err)
(message "Deactivating scripts...done")
- (message "Deactivating scripts...failed" (nth 2 err)))))
+ (message "Deactivating scripts...failed: %s" (nth 2 err)))))
(defalias 'sieve-deactivate 'sieve-deactivate-all)
(defcustom spam-report-url-ping-function
'spam-report-url-ping-plain
- "Function to use for url ping spam reporting."
+ "Function to use for url ping spam reporting.
+The function must accept the arguments `host' and `report'."
:type '(choice
(const :tag "Connect directly"
spam-report-url-ping-plain)
(const :tag "Use the external program specified in `mm-url-program'"
- spam-report-url-ping-mm-url))
+ spam-report-url-ping-mm-url)
+ (const :tag "Store request URLs in `spam-report-requests-file'"
+ spam-report-url-to-file)
+ (function :tag "User defined function" nil))
+ :group 'spam-report)
+
+(defcustom spam-report-requests-file
+ (nnheader-concat gnus-directory "spam/" "spam-report-requests.url")
+ ;; Is there a convention for the extension of such a file?
+ ;; Should we use `spam-directory'?
+ "File where spam report request are stored."
+ :type 'file
:group 'spam-report)
(defun spam-report-gmane (&rest articles)
the external program specified in `mm-url-program' to connect to
server."
(with-temp-buffer
- (let ((url (concat "http://" host "/" report)))
+ (let ((url (concat "http://" host report)))
(mm-url-insert url t))))
+(defun spam-report-url-to-file (host report)
+ "Collect spam report requests in `spam-report-requests-file'.
+Customize `spam-report-url-ping-function' to use this function."
+ (let ((url (concat "http://" host report))
+ (file spam-report-requests-file))
+ (gnus-make-directory (file-name-directory file))
+ (gnus-message 9 "Writing URL `%s' to file `%s'" url file)
+ (with-temp-buffer
+ (insert url)
+ (newline)
+ (append-to-file (point-min) (point-max) file))))
+
(provide 'spam-report)
;;; spam-report.el ends here.
(defgroup spam nil
"Spam configuration.")
-(defcustom spam-directory "~/News/spam/"
+(defcustom spam-directory (nnheader-concat gnus-directory "spam/")
"Directory for spam whitelists and blacklists."
:type 'directory
:group 'spam)
(gnus-group-spam-exit-processor-ifile spam spam-use-ifile)
(gnus-group-spam-exit-processor-stat spam spam-use-stat)
(gnus-group-spam-exit-processor-spamoracle spam spam-use-spamoracle)
- (gnus-group-spam-exit-processor-spamassassin spam spam-use-spam-spamassassin)
+ (gnus-group-spam-exit-processor-spamassassin spam spam-use-spamassassin)
(gnus-group-ham-exit-processor-ifile ham spam-use-ifile)
(gnus-group-ham-exit-processor-bogofilter ham spam-use-bogofilter)
(gnus-group-ham-exit-processor-stat ham spam-use-stat)
(gnus-group-ham-exit-processor-whitelist ham spam-use-whitelist)
(gnus-group-ham-exit-processor-BBDB ham spam-use-BBDB)
(gnus-group-ham-exit-processor-copy ham spam-use-ham-copy)
- (gnus-group-ham-exit-processor-spamassassin ham spam-use-ham-spamassassin)
+ (gnus-group-ham-exit-processor-spamassassin ham spam-use-spamassassin)
(gnus-group-ham-exit-processor-spamoracle ham spam-use-spamoracle))
"The `spam-list-of-processors' list.
This list contains pairs associating a ham/spam exit processor
(goto-char (point-min))
(when (re-search-forward "^X-Spam: yes;" nil t)
spam-split-group))
- (error "Error running spamoracle" status))))))))
+ (error "Error running spamoracle: %s" status))))))))
(defun spam-spamoracle-learn (articles article-is-spam-p &optional unregister)
"Run spamoracle in training mode."
`("-f" ,spam-spamoracle-database
"add" ,arg)
`("add" ,arg)))))
- (when (not (eq 0 status))
- (error "Error running spamoracle" status)))))))
+ (unless (eq 0 status)
+ (error "Error running spamoracle: %s" status)))))))
(defun spam-spamoracle-learn-ham (articles &optional unregister)
(spam-spamoracle-learn articles nil unregister))
+2004-02-03 Reiner Steib <Reiner.Steib@gmx.de>
+
+ * gnus.texi (Batching Agents): Fixed typo in example. Reported
+ by Hiroshi Fujishima <pooh@nature.tsukuba.ac.jp>.
+
2004-01-30 Jesper Harder <harder@ifa.au.dk>
* gnus.texi: Set documentencoding.
@example
#!/bin/sh
-emacs -batch -l ~/.emacs -f -l ~/.gnus.el gnus-agent-batch >/dev/null 2>&1
+emacs -batch -l ~/.emacs -l ~/.gnus.el gnus-agent-batch >/dev/null 2>&1
@end example
@node Control Agents
@example
#!/bin/sh
-emacs -batch -l ~/.emacs -f -l ~/.gnus.el gnus-agent-batch >/dev/null 2>&1
+emacs -batch -l ~/.emacs -l ~/.gnus.el gnus-agent-batch >/dev/null 2>&1
@end example