From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/58091 Path: main.gmane.org!not-for-mail From: dhedbor@real.com Newsgroups: gmane.emacs.gnus.general Subject: Re: small patch for nnmail (lowercase expand option) Date: Thu, 08 Jul 2004 16:11:33 -0700 Sender: ding-owner@lists.math.uh.edu Message-ID: <87y8luhz6i.fsf@real.com> References: <874qoije07.fsf@real.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=_flawless.real.com-3961-1089328291-0001-2" X-Trace: sea.gmane.org 1089328383 29005 80.91.224.253 (8 Jul 2004 23:13:03 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 8 Jul 2004 23:13:03 +0000 (UTC) Original-X-From: ding-owner+M6632@lists.math.uh.edu Fri Jul 09 01:12:54 2004 Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Bii4T-00068H-00 for ; Fri, 09 Jul 2004 01:12:53 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 1Bii3L-0001Yy-00; Thu, 08 Jul 2004 18:11:43 -0500 Original-Received: from util2.math.uh.edu ([129.7.128.23]) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 1Bii3H-0001Yt-00 for ding@lists.math.uh.edu; Thu, 08 Jul 2004 18:11:39 -0500 Original-Received: from justine.libertine.org ([66.139.78.221] ident=postfix) by util2.math.uh.edu with esmtp (Exim 4.30) id 1Bii3E-0008Lo-V2 for ding@lists.math.uh.edu; Thu, 08 Jul 2004 18:11:36 -0500 Original-Received: from flawless.real.com (flawless.real.com [207.188.23.141]) by justine.libertine.org (Postfix) with ESMTP id 50DB53A0035 for ; Thu, 8 Jul 2004 18:11:36 -0500 (CDT) Original-Received: from atlantis ([::ffff:172.22.133.243]) by flawless.real.com with esmtp; Thu, 08 Jul 2004 16:11:31 -0700 Original-To: ding@gnus.org In-Reply-To: <874qoije07.fsf@real.com> (dhedbor@real.com's message of "Thu, 08 Jul 2004 16:06:00 -0700") Original-Lines: 11 User-Agent: Gnus/5.110003 (No Gnus v0.3) XEmacs/21.4 (Security Through Obscurity, linux) Precedence: bulk Xref: main.gmane.org gmane.emacs.gnus.general:58091 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:58091 This is a MIME-formatted message. If you see this text it means that your E-mail software does not support MIME-formatted messages. --=_flawless.real.com-3961-1089328291-0001-2 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 7bit dhedbor@real.com writes: > + "Whether to match lowercase expanded entries (i.e \\N) or leave them Typo in the documentation. That "match" shouldn't be there. New patch attached. -- David Hedbor, Software Development Engineer - Real Networks Helix Community: http://helixcommunity.org --=_flawless.real.com-3961-1089328291-0001-2 Content-Type: text/x-patch; charset=iso-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename=nnmail-expand-lowercase.patch Index: lisp/nnmail.el =================================================================== RCS file: /usr/local/cvsroot/gnus/lisp/nnmail.el,v retrieving revision 7.9 diff -u -r7.9 nnmail.el --- lisp/nnmail.el 20 May 2004 08:02:40 -0000 7.9 +++ lisp/nnmail.el 8 Jul 2004 23:10:35 -0000 @@ -574,6 +574,15 @@ :group 'nnmail :type 'boolean) +(defcustom nnmail-split-fancy-lowercase-expanded nil + + "Whether to lowercase expanded entries (i.e \\N) or leave them as-is +when using fancy splitting. This avoids the creation of multiple +groups when users send to an address using different case (i.e +mailing-list@domain vs Mailing-List@Domain)." + :group 'nnmail + :type 'boolean) + ;;; Internal variables. (defvar nnmail-article-buffer " *nnmail incoming*" @@ -1464,8 +1473,11 @@ (setq N 0) (setq N (- c ?0))) (when (match-beginning N) - (push (buffer-substring (match-beginning N) (match-end N)) - expanded)))) + (let ((tmp-match (buffer-substring (match-beginning N) + (match-end N)))) + (if nnmail-split-fancy-lowercase-expanded + (push (downcase tmp-match) expanded) + (push tmp-match expanded)))))) (setq pos (1+ pos))) (if did-expand (apply 'concat (nreverse expanded)) --=_flawless.real.com-3961-1089328291-0001-2--