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

Expiry problems...



I use auto-expire and, as expected, articles are marked "E" for later expiry.
I also arrange for expiry to take place using the gnus-demon facility rather
than each time I exit the summary buffer (I originally did this when I used
nnml because expiry was noticeably slow for me).

However, since switching to nnimap, I now notice that many articles which
should have been expired (marked E and older than 7 days) are now displayed
with the ancient "O" mark when I enter the group with a prefix argument.

Any idea what's happening?  With nnimap, does expiry have to occur when I exit
the summary buffer for it to work properly?

I've appended the elisp I use below...

Thanks,

    --- John

;; Have groups expired after Emacs has been idle for an hour, rather than after
;; exiting each summary buffer.
(remove-hook 'gnus-summary-prepare-exit-hook 'gnus-summary-expire-articles)
(gnus-demon-add-handler 'jsc-expire-groups nil 60)

(defun jsc-expire-groups ()
  "Expire all groups"
  (when (gnus-alive-p)
    (gnus-group-expire-all-groups)
    (message "Expired all Gnus groups")))

;; For manually forcing expiry
(defun jsc-lunch ()
  "Expire all mail groups"
  (interactive)
  (gnus-group-expire-all-groups))
(global-set-key [f12] 'jsc-lunch)