info-gnus-english
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gnus: expiring unread articles


From: Mark T.B. Carroll
Subject: Re: Gnus: expiring unread articles
Date: Tue, 08 Nov 2005 12:57:44 -0500
User-agent: Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux)

Bastien <bastien@xxx.fr> writes:

> Don't steal! Just use :)  And YES, spam.el is very useful.

(-: In the spirit of sharing, here's what I came up with for the
expiration. In conjunction with auto expire, it appears to be enough to
do,

(defun gnus-expire-spam ()
 "Expire SPAM articles."
 (interactive)
 (gnus-activate-group gnus-spam-group)
 (let ((number-read (gnus-group-catchup gnus-spam-group t)))
   (cond ((not (numberp number-read)) (message "Failed to expire spam."))
         ((= 0 number-read) (message "Expired no spam articles."))
         ((= 1 number-read) (message "Expired 1 spam article."))
         ( t                (message "Expired %i spam articles." number-read))))
 (gnus-group-update-group gnus-spam-group t))

I don't really know what I'm doing, TBH - I only started using Gnus at
all a week ago, and have never written much elisp, but this seems to
work well enough.

-- Mark


reply via email to

[Prev in Thread] Current Thread [Next in Thread]