+2002-02-09 TSUCHIYA Masatoshi <tsuchiya@namazu.org>
+
+ * lisp/gnus-namazu.el (gnus-namazu/group-alist): Abolished.
+ (gnus-namazu/setup): Not set it.
+ (gnus-namazu/shutdown): Removed.
+ (gnus-namazu/group-prefixed-name): Handle case-insensitive file
+ names by itself.
+
+2002-02-09 NISHIDA Masakazu <m_nisida@ca2.so-net.ne.jp>
+
+ * lisp/gnus-namazu.el (gnus-namazu/complete-query): Relaxed the
+ regexp which matches field search keywords.
+
2002-02-01 ShengHuo ZHU <zsh@cs.rochester.edu>
* etc/gnus/gnus.xpm: Remove some garbages at the end of the file.
:group 'gnus-namazu)
;;; Internal Variable:
-(defvar gnus-namazu/group-alist nil
- "Associative list to map groups in lower case to official names.")
(defconst gnus-namazu/group-name-regexp "\\`nnvirtual:namazu-search\\?")
;; Multibyte group name:
(setcdr pair gnus-namazu-coding-system)
(push (cons gnus-namazu/group-name-regexp
gnus-namazu-coding-system)
- gnus-group-name-charset-group-alist))))
- (unless gnus-namazu-case-sensitive-filesystem
- ;; FIXME: The alist to map group names in lower case to real names
- ;; is reconstructed every when gnus-namazu/setup() is called.
- ;; This reconstruction make gnus-namazu-search() slow.
- (setq gnus-namazu/group-alist nil)
- (dolist (server (gnus-namazu/indexed-servers))
- (dolist (group (gnus-namazu/request-list server))
- (let ((name (gnus-group-prefixed-name group server)))
- (unless (assoc name gnus-namazu/group-alist)
- (push (cons (downcase name) name) gnus-namazu/group-alist)))))))
-
-(defun gnus-namazu/shutdown ()
- (setq gnus-namazu/group-alist nil))
-(add-hook 'gnus-exit-gnus-hook 'gnus-namazu/shutdown)
+ gnus-group-name-charset-group-alist)))))
(defun gnus-namazu/request-list (server)
"Return groups of the server SERVER."
"Return the whole name from GROUP and METHOD."
(if gnus-namazu-case-sensitive-filesystem
(gnus-group-prefixed-name group method)
- (let ((name (gnus-group-prefixed-name group method)))
- (or (cdr (assoc (downcase name) gnus-namazu/group-alist))
- name))))
+ (let* ((orig (gnus-group-prefixed-name group method))
+ (name (downcase orig)))
+ (catch 'found-group
+ (mapatoms (lambda (sym)
+ (when (string= name (downcase (symbol-name sym)))
+ (throw 'found-group (symbol-name sym))))
+ gnus-newsrc-hashtb)
+ orig))))
(defun gnus-namazu/check-cache-group (str)
"Get the news group from the partial path STR of the cached article."
(interactive)
(let ((pos (point)))
(cond
- ((and (re-search-backward "\\+\\([a-z]*\\)" nil t)
+ ((and (re-search-backward "\\+\\([-a-z]*\\)" nil t)
(= pos (match-end 0)))
(let* ((partial (match-string 1))
(completions