diff options
author | Kyle Meyer <kyle@kyleam.com> | 2015-02-11 23:27:19 -0500 |
---|---|---|
committer | Kyle Meyer <kyle@kyleam.com> | 2015-02-11 23:27:19 -0500 |
commit | 544adc43c39bdae8230205209d5893b75af3bef9 (patch) | |
tree | fbb518f28e28bb5eec1e9029c5851423eb98ecff /lisp | |
parent | 07c050efe54a0f7902adea7cae84ee59f54a65a4 (diff) | |
download | emacs.d-544adc43c39bdae8230205209d5893b75af3bef9.tar.gz |
gnus: Add ido variants for group and topic jumping
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/init-gnus.el | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/lisp/init-gnus.el b/lisp/init-gnus.el index f95f11c..a4657bc 100644 --- a/lisp/init-gnus.el +++ b/lisp/init-gnus.el @@ -1,6 +1,4 @@ (require 'gnus) -(autoload 'gnus-group-topic "gnus-topic") - (require 'org-gnus) (setq gnus-home-directory "~/.gnus.d/" @@ -79,6 +77,28 @@ is off." (string< (gnus-group-topic (gnus-info-group info1)) (gnus-group-topic (gnus-info-group info2)))) +(autoload 'gnus-group-topic "gnus-topic") +(defun km/gnus-group-jump-to-group () + "`gnus-group-jump-to-group', but with ido completion." + (interactive) + (gnus-group-jump-to-group + (ido-completing-read "Group: " + (mapcar #'car (cdr gnus-newsrc-alist)) + nil t))) + +(defun km/gnus-topic-jump-to-topic () + "`gnus-group-jump-to-group', but with ido completion." + (interactive) + (gnus-topic-jump-to-topic + (ido-completing-read "Topic: " + (mapcar #'car gnus-topic-alist) + nil t))) + +(define-key gnus-group-mode-map [remap gnus-group-jump-to-group] + 'km/gnus-group-jump-to-group) +(define-key gnus-group-mode-map [remap gnus-topic-jump-to-topic] + 'km/gnus-topic-jump-to-topic) + (define-key gnus-group-mode-map "e" 'gnus-group-select-group) |