Gnus development mailing list
 help / color / mirror / Atom feed
From: Katsumi Yamaoka <yamaoka@jpl.org>
Cc: IRIE Tetsuya <irie@t.email.ne.jp>
Subject: gnus-parameters ignores case
Date: Tue, 01 Nov 2005 14:57:27 +0900	[thread overview]
Message-ID: <b4mbr14rjug.fsf@jpl.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 406 bytes --]

Hi,

IRIE Tetsuya reported that he lost all mails in the INBOX.foo
group when he set `gnus-parameters' to:

(setq gnus-parameters '(("INBOX\\.FOO" (total-expire . t))))

He meant having added that parameter to the INBOX.FOO group, not
INBOX.foo group, however it was applied to both the groups.  To
solve this problem, I propose the following changes.  WDYT?

Plan 1: This might trouble some other users.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 384 bytes --]

--- gnus.el~	2005-09-16 01:51:50 +0000
+++ gnus.el	2005-11-01 05:53:07 +0000
@@ -3769,7 +3769,8 @@
 
 (defun gnus-parameters-get-parameter (group)
   "Return the group parameters for GROUP from `gnus-parameters'."
-  (let (params-list)
+  (let ((case-fold-search nil)
+	params-list)
     (dolist (elem gnus-parameters)
       (when (string-match (car elem) group)
 	(setq params-list

[-- Attachment #3: Type: text/plain, Size: 63 bytes --]


Plan 2: This does the same behavior as the conventional one.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: Type: text/x-patch, Size: 1093 bytes --]

--- gnus.el~	2005-09-16 01:51:50 +0000
+++ gnus.el	2005-11-01 05:53:08 +0000
@@ -1100,6 +1100,16 @@
   :type '(repeat (cons regexp
 		       (repeat sexp))))
 
+(defcustom gnus-parameters-case-fold-search 'default
+  "If it is t, ignore case of group names specified in `gnus-parameters'.
+If it is nil, don't ignore case.  If it is `default', which is for the
+backward compatibility, use the value of `case-fold-search'."
+  :version "22.1"
+  :group 'gnus-group-various
+  :type '(radio (const :tag "Use `case-fold-search'" default)
+		(const nil)
+		(const t)))
+
 (defvar gnus-group-parameters-more nil)
 
 (defmacro gnus-define-group-parameter (param &rest rest)
@@ -3769,7 +3779,10 @@
 
 (defun gnus-parameters-get-parameter (group)
   "Return the group parameters for GROUP from `gnus-parameters'."
-  (let (params-list)
+  (let ((case-fold-search (if (eq gnus-parameters-case-fold-search 'default)
+			      case-fold-search
+			    gnus-parameters-case-fold-search))
+	params-list)
     (dolist (elem gnus-parameters)
       (when (string-match (car elem) group)
 	(setq params-list

             reply	other threads:[~2005-11-01  5:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-01  5:57 Katsumi Yamaoka [this message]
2005-11-01 23:29 ` Katsumi Yamaoka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b4mbr14rjug.fsf@jpl.org \
    --to=yamaoka@jpl.org \
    --cc=irie@t.email.ne.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).