aboutsummaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/mastodon.el11
1 files changed, 11 insertions, 0 deletions
diff --git a/lisp/mastodon.el b/lisp/mastodon.el
index 9cf19b2..a49d0cc 100644
--- a/lisp/mastodon.el
+++ b/lisp/mastodon.el
@@ -368,6 +368,17 @@ Calls `mastodon-tl--get-buffer-type', which see."
(cl-loop for x in mastodon-buffers
do (kill-buffer x))))
+(defun mastodon-switch-to-buffer ()
+ "Switch to a live mastodon buffer."
+ (interactive)
+ (let* ((bufs (mastodon-live-buffers))
+ (buf-names (mapcar (lambda (buf)
+ (buffer-name buf))
+ bufs))
+ (choice (completing-read "Switch to mastodon buffer: "
+ buf-names)))
+ (switch-to-buffer choice)))
+
;;;###autoload
(add-hook 'mastodon-mode-hook (lambda ()
(when (require 'emojify nil :noerror)