From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/68575 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.gnus.general Subject: auto auto-expirable Date: Fri, 29 May 2009 20:19:15 +0900 Organization: Emacsen advocacy group Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1243596068 32069 80.91.229.12 (29 May 2009 11:21:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 29 May 2009 11:21:08 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M17006@lists.math.uh.edu Fri May 29 13:21:05 2009 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.50) id 1MA092-0000uq-PG for ding-account@gmane.org; Fri, 29 May 2009 13:21:05 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1MA08H-00017P-LI; Fri, 29 May 2009 06:20:17 -0500 Original-Received: from mx1.math.uh.edu ([129.7.128.32]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1MA08G-00017F-Fd for ding@lists.math.uh.edu; Fri, 29 May 2009 06:20:16 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtp (Exim 4.69) (envelope-from ) id 1MA07z-0004hO-SL for ding@lists.math.uh.edu; Fri, 29 May 2009 06:20:16 -0500 Original-Received: from orlando.hostforweb.net ([216.246.45.90]) by quimby.gnus.org with esmtp (Exim 3.36 #1 (Debian)) id 1MA08T-0000O5-00 for ; Fri, 29 May 2009 13:20:29 +0200 Original-Received: from localhost ([127.0.0.1]:39097) by orlando.hostforweb.net with esmtpa (Exim 4.69) (envelope-from ) id 1MA07S-0001kn-0V for ding@gnus.org; Fri, 29 May 2009 06:19:26 -0500 X-Hashcash: 1:20:090529:ding@gnus.org::RnMUShKJqZO8aZH3:0000IuuS X-Face: #kKnN,xUnmKia.'[pp`;Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu;B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.0.94 (gnu/linux) Cancel-Lock: sha1:sFSHg5RWoJhcOE9/MmLvNBTlEyo= X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - orlando.hostforweb.net X-AntiAbuse: Original Domain - gnus.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: X-Spam-Score: -2.6 (--) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:68575 Archived-At: --=-=-= The expirable mark of a read article if any is stripped when it is copied or moved to the group in which to do not automatically mark read articles as expirable. That is good. However, it will not be marked as expirable when copying or moving a read article (that has not been marked as expirable) to the group in which to automatically mark read articles as expirable. So, such an article will never be expired unless it is read. Actually I have a number of such articles in the auto-expirable groups. The attached patch solves it, i.e., read articles copied or moved to auto-expirable group are automatically marked as expirable. Does anyone see any harm with this change? Though I will not commit it until the next release anyway. --=-=-= Content-Type: text/x-patch Content-Disposition: inline --- gnus-sum.el~ 2009-02-05 09:09:28 +0000 +++ gnus-sum.el 2009-05-29 09:45:03 +0000 @@ -9753,10 +9753,8 @@ (list (cdr art-group))))) ;; See whether the article is to be put in the cache. - (let ((marks (if (gnus-group-auto-expirable-p to-group) - gnus-article-mark-lists - (delete '(expirable . expire) - (copy-sequence gnus-article-mark-lists)))) + (let ((marks (delete '(expirable . expire) + (copy-sequence gnus-article-mark-lists))) (to-article (cdr art-group))) ;; Enter the article into the cache in the new group, @@ -9796,6 +9794,15 @@ to-group (cdar marks) (list to-article) info))) (setq marks (cdr marks))) + (when (gnus-group-auto-expirable-p to-group) + ;; Mark this article as expirable + (push 'expire to-marks) + (when (equal to-group gnus-newsgroup-name) + (push to-article gnus-newsgroup-expirable)) + ;; Copy the expirable mark to other group. + (gnus-add-marked-articles + to-group 'expire (list to-article) info)) + (gnus-request-set-mark to-group (list (list (list to-article) 'add to-marks)))) --=-=-=--