diff options
| -rw-r--r-- | lisp/gnus/ChangeLog | 7 | ||||
| -rw-r--r-- | lisp/gnus/nnir.el | 47 |
2 files changed, 25 insertions, 29 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index a9424496bd7..7dab1382564 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2010-11-01 Andrew Cohen <cohen@andy.bu.edu> | ||
| 2 | |||
| 3 | * nnir.el (nnir-run-gmane): inhibit demon. return nil if no messages. | ||
| 4 | (nnir-read-parms): don't modify query. | ||
| 5 | (nnir-run-query): add ability to search topic on current line. | ||
| 6 | (nnir-get-active): clean up. | ||
| 7 | |||
| 1 | 2010-11-01 Lars Magne Ingebrigtsen <larsi@gnus.org> | 8 | 2010-11-01 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 2 | 9 | ||
| 3 | * gnus-cite.el (gnus-article-foldable-buffer): Protect against | 10 | * gnus-cite.el (gnus-article-foldable-buffer): Protect against |
diff --git a/lisp/gnus/nnir.el b/lisp/gnus/nnir.el index bfe4df8ee1b..52cce769148 100644 --- a/lisp/gnus/nnir.el +++ b/lisp/gnus/nnir.el | |||
| @@ -1407,6 +1407,7 @@ Tested with Namazu 2.0.6 on a GNU/Linux system." | |||
| 1407 | (format "author:%s" (cdr (assq 'author query))) "")) | 1407 | (format "author:%s" (cdr (assq 'author query))) "")) |
| 1408 | (search (format "%s %s %s" | 1408 | (search (format "%s %s %s" |
| 1409 | qstring groupspec authorspec)) | 1409 | qstring groupspec authorspec)) |
| 1410 | (gnus-inhibit-demon t) | ||
| 1410 | artlist) | 1411 | artlist) |
| 1411 | (require 'mm-url) | 1412 | (require 'mm-url) |
| 1412 | (with-current-buffer nntp-server-buffer | 1413 | (with-current-buffer nntp-server-buffer |
| @@ -1441,14 +1442,15 @@ Tested with Namazu 2.0.6 on a GNU/Linux system." | |||
| 1441 | (function (lambda (x y) | 1442 | (function (lambda (x y) |
| 1442 | (> (nnir-artitem-rsv x) | 1443 | (> (nnir-artitem-rsv x) |
| 1443 | (nnir-artitem-rsv y))))))) | 1444 | (nnir-artitem-rsv y))))))) |
| 1444 | (message "Can't search non-gmane nntp groups"))) | 1445 | (message "Can't search non-gmane nntp groups") |
| 1446 | nil)) | ||
| 1445 | 1447 | ||
| 1446 | ;;; Util Code: | 1448 | ;;; Util Code: |
| 1447 | 1449 | ||
| 1448 | (defun nnir-read-parms (query nnir-search-engine) | 1450 | (defun nnir-read-parms (query nnir-search-engine) |
| 1449 | "Reads additional search parameters according to `nnir-engines'." | 1451 | "Reads additional search parameters according to `nnir-engines'." |
| 1450 | (let ((parmspec (caddr (assoc nnir-search-engine nnir-engines)))) | 1452 | (let ((parmspec (caddr (assoc nnir-search-engine nnir-engines)))) |
| 1451 | (nconc query | 1453 | (append query |
| 1452 | (mapcar 'nnir-read-parm parmspec)))) | 1454 | (mapcar 'nnir-read-parm parmspec)))) |
| 1453 | 1455 | ||
| 1454 | (defun nnir-read-parm (parmspec) | 1456 | (defun nnir-read-parm (parmspec) |
| @@ -1472,7 +1474,11 @@ Tested with Namazu 2.0.6 on a GNU/Linux system." | |||
| 1472 | (with-current-buffer gnus-server-buffer | 1474 | (with-current-buffer gnus-server-buffer |
| 1473 | (list (list (gnus-server-server-name)))) | 1475 | (list (list (gnus-server-server-name)))) |
| 1474 | (nnir-sort-groups-by-server | 1476 | (nnir-sort-groups-by-server |
| 1475 | (or gnus-group-marked (list (gnus-group-group-name))))))) | 1477 | (or gnus-group-marked |
| 1478 | (if (gnus-group-group-name) | ||
| 1479 | (list (gnus-group-group-name)) | ||
| 1480 | (cdr (assoc (gnus-group-topic-name) | ||
| 1481 | gnus-topic-alist)))))))) | ||
| 1476 | (apply 'vconcat | 1482 | (apply 'vconcat |
| 1477 | (mapcar (lambda (x) | 1483 | (mapcar (lambda (x) |
| 1478 | (let* ((server (car x)) | 1484 | (let* ((server (car x)) |
| @@ -1582,32 +1588,15 @@ artitem (counting from 1)." | |||
| 1582 | (goto-char (point-min)) | 1588 | (goto-char (point-min)) |
| 1583 | (unless (string= gnus-ignored-newsgroups "") | 1589 | (unless (string= gnus-ignored-newsgroups "") |
| 1584 | (delete-matching-lines gnus-ignored-newsgroups)) | 1590 | (delete-matching-lines gnus-ignored-newsgroups)) |
| 1585 | ;; We treat NNTP as a special case to avoid problems with | 1591 | (while (not (eobp)) |
| 1586 | ;; garbage group names like `"foo' that appear in some badly | 1592 | (ignore-errors |
| 1587 | ;; managed active files. -jh. | 1593 | (push (mm-string-as-unibyte |
| 1588 | (if (eq (car method) 'nntp) | 1594 | (let ((p (point))) |
| 1589 | (while (not (eobp)) | 1595 | (skip-chars-forward "^ \t\\\\") |
| 1590 | (ignore-errors | 1596 | (setq name (buffer-substring (+ p 1) (- (point) 1))) |
| 1591 | (push (cons | 1597 | (gnus-group-full-name name method))) |
| 1592 | (mm-string-as-unibyte | 1598 | groups)) |
| 1593 | (buffer-substring | 1599 | (forward-line)))) |
| 1594 | (point) | ||
| 1595 | (progn | ||
| 1596 | (skip-chars-forward "^ \t") | ||
| 1597 | (point)))) | ||
| 1598 | (let ((last (read cur))) | ||
| 1599 | (cons (read cur) last))) | ||
| 1600 | groups)) | ||
| 1601 | (forward-line)) | ||
| 1602 | (while (not (eobp)) | ||
| 1603 | (ignore-errors | ||
| 1604 | (push (mm-string-as-unibyte | ||
| 1605 | (let ((p (point))) | ||
| 1606 | (skip-chars-forward "^ \t\\\\") | ||
| 1607 | (setq name (buffer-substring (+ p 1) (- (point) 1))) | ||
| 1608 | (gnus-group-full-name name method))) | ||
| 1609 | groups)) | ||
| 1610 | (forward-line))))) | ||
| 1611 | groups)) | 1600 | groups)) |
| 1612 | 1601 | ||
| 1613 | ;; The end. | 1602 | ;; The end. |