From: kose Date: Thu, 4 Mar 2004 02:38:03 +0000 (+0000) Subject: (gnus-namazu-command-prefix): New variable. X-Git-Tag: t-gnus-6_17_4-quimby-~1040 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2e10111f08ae2cf78addf4bfcb9cb0f41f4f3fdd;p=elisp%2Fgnus.git- (gnus-namazu-command-prefix): New variable. (gnus-namazu-imap-group-prefix): Ditto. (gnus-namazu/directory-table-use): Ditto. (gnus-namazu/call-namazu): Use gnus-namazu-imap-group-prefix. (gnus-namazu/search): Support Maildir. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7114bc6..7f4088b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2004-03-04 KOSEKI Yoshinori + + * gnus-namazu.el (gnus-namazu-command-prefix): New variable. + (gnus-namazu-imap-group-prefix): Ditto. + (gnus-namazu/directory-table-use): Ditto. + (gnus-namazu/call-namazu): Use gnus-namazu-imap-group-prefix. + (gnus-namazu/search): Support Maildir. + 2004-03-04 Katsumi Yamaoka * rfc2047.el (rfc2047-encoded-word-regexp): Mismatched paren. diff --git a/lisp/gnus-namazu.el b/lisp/gnus-namazu.el index d33afb6..31409fd 100644 --- a/lisp/gnus-namazu.el +++ b/lisp/gnus-namazu.el @@ -211,6 +211,24 @@ options make any sense in this context." "Face used for namazu query matching words." :group 'gnus-namazu) +(defcustom gnus-namazu-command-prefix nil + "*Prefix command, +if set '(\"ssh\" \"-x\" \"host\"), +then execute \"ssh -x host namazu ...\"" + :type '(repeat string) + :group 'gnus-namazu) + +(defcustom gnus-namazu-imap-group-prefix nil + "*Prefix of imap group name. +ex. nnimap+server:INBOX." + :type 'string + :group 'gnus-namazu) + +(defcustom gnus-namazu/directory-table-use t + "*Non-nil, use gnus-namazu/directory-table." + :type 'boolean + :group 'gnus-namazu) + ;;; Internal Variable: (defconst gnus-namazu/group-name-regexp "\\`nnvirtual:namazu-search\\?") @@ -295,17 +313,30 @@ options make any sense in this context." (cons gnus-namazu-coding-system gnus-namazu-coding-system)) program-coding-system-alist (file-name-coding-system gnus-namazu-coding-system)) - (apply 'call-process - `(,gnus-namazu-command - nil ; input from /dev/null - t ; output - nil ; don't redisplay - "-q" ; don't be verbose - "-a" ; show all matches - "-l" ; use list format - ,@gnus-namazu-additional-arguments - ,query - ,@gnus-namazu-index-directories)))) + (if gnus-namazu-command-prefix + (apply 'call-process + (append + (list (car gnus-namazu-command-prefix)) + '(nil t nil) + (cdr gnus-namazu-command-prefix) + `(,gnus-namazu-command + "-q" ; don't be verbose + "-a" ; show all matches + "-l" ; use list format + ,@gnus-namazu-additional-arguments + ,query + ,@gnus-namazu-index-directories))) + (apply 'call-process + `(,gnus-namazu-command + nil ; input from /dev/null + t ; output + nil ; don't redisplay + "-q" ; don't be verbose + "-a" ; show all matches + "-l" ; use list format + ,@gnus-namazu-additional-arguments + ,query + ,@gnus-namazu-index-directories))))) (defvar gnus-namazu/directory-table nil) (defun gnus-namazu/make-directory-table (&optional force) @@ -361,12 +392,22 @@ options make any sense in this context." ;; as file names of articles. (skip-chars-backward "0-9") (point)))) - (and (setq group - (symbol-value - (intern-soft (if gnus-namazu-case-sensitive-filesystem - group - (downcase group)) - (cdr gnus-namazu/directory-table)))) + (and (if gnus-namazu/directory-table-use + (setq group + (symbol-value + (intern-soft (if gnus-namazu-case-sensitive-filesystem + group + (downcase group)) + (cdr gnus-namazu/directory-table)))) + ;; FIXME: + ;; gnus-select-method is '(nnimap "server") + ;; nnimap+server:INBOX.group = ~/Maildir/.group + ;; Namazu resault: ~/Maildir/.group/123 + (setq group (and (string-match + (concat (expand-file-name "~/Maildir") + "/\\.\\(.*\\)/") group) + (concat gnus-namazu-imap-group-prefix + (match-string 1 group))))) (or (not groups) (member group groups)) (push (gnus-namazu/make-article