[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] feature/gnus-select ddfd397: Improve search and select gro
From: |
Andrew G Cohen |
Subject: |
[Emacs-diffs] feature/gnus-select ddfd397: Improve search and select group creation |
Date: |
Sat, 13 May 2017 03:06:42 -0400 (EDT) |
branch: feature/gnus-select
commit ddfd3973057115f96a777ba6e597132a8d38b0ba
Author: Andrew G Cohen <address@hidden>
Commit: Andrew G Cohen <address@hidden>
Improve search and select group creation
* lisp/gnus/gnus-group.el (gnus-group-make-search-group): Make sure
new group is inserted into the group buffer.
* lisp/gnus/nnselect.el (nnselect-request-create-group): Improve input
of selection function.
---
lisp/gnus/gnus-group.el | 23 ++++++++++++-----------
lisp/gnus/nnselect.el | 2 +-
2 files changed, 13 insertions(+), 12 deletions(-)
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el
index 7f4822c..71527ab 100644
--- a/lisp/gnus/gnus-group.el
+++ b/lisp/gnus/gnus-group.el
@@ -3200,17 +3200,18 @@ mail messages or news articles in files that have
numeric names."
;; Temporary to make group creation easier
(defun gnus-group-make-search-group (nnir-extra-parms &optional specs)
(interactive "P")
- (let ((name (read-string "Group name: " nil)))
- (gnus-group-make-group
- name
- (list 'nnselect "nnselect")
- nil
- (list
- (cons 'nnselect-specs
- (list
- (cons 'nnselect-function 'nnir-run-query)
- (cons 'nnselect-args
- (nnir-make-specs nnir-extra-parms specs))))))))
+ (let ((name (gnus-read-group "Group name: ")))
+ (with-current-buffer gnus-group-buffer
+ (gnus-group-make-group
+ name
+ (list 'nnselect "nnselect")
+ nil
+ (list
+ (cons 'nnselect-specs
+ (list
+ (cons 'nnselect-function 'nnir-run-query)
+ (cons 'nnselect-args
+ (nnir-make-specs nnir-extra-parms specs)))))))))
(defun gnus-group-read-ephemeral-search-group (nnir-extra-parms
&optional specs)
"Create an nnselect group based on a search. Prompt for a
diff --git a/lisp/gnus/nnselect.el b/lisp/gnus/nnselect.el
index 793775f..132f9dd 100644
--- a/lisp/gnus/nnselect.el
+++ b/lisp/gnus/nnselect.el
@@ -586,7 +586,7 @@ If this variable is nil, or if the provided function
returns nil,
(specs (assq 'nnselect-specs args))
(function-spec
(or (alist-get 'nnselect-function specs)
- (read-from-minibuffer "Function: " nil nil t)))
+ (intern (completing-read "Function: " obarray #'functionp))))
(args-spec
(or (alist-get 'nnselect-args specs)
(read-from-minibuffer "Args: " nil nil t nil "nil")))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] feature/gnus-select ddfd397: Improve search and select group creation,
Andrew G Cohen <=