summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--tag-emacs/emacs.d/init.org11
1 files changed, 10 insertions, 1 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org
index 392f76e0..991af461 100644
--- a/tag-emacs/emacs.d/init.org
+++ b/tag-emacs/emacs.d/init.org
@@ -1198,7 +1198,16 @@ replace helm and ido.
            ("<apps>" . counsel-M-x)
            ("<menu>" . counsel-M-x)
            ("C-c M-x" . execute-extended-command)
-           ("C-x C-f" . counsel-find-file)))
+           ("C-x C-f" . counsel-find-file)
+           ("C-x b" . counsel-switch-to-projectile-buffer))
+    :config (progn
+              (defun counsel-switch-to-projectile-buffer (arg)
+                "Forward to `projectile-switch-to-buffer'."
+                (ivy-read (format "Switch to buffer [%s]: " (projectile-project-name))
+                          (projectile-project-buffer-names)
+                          :preselect (buffer-name (other-buffer (current-buffer)))
+                          :action #'ivy--switch-buffer-action
+                          :keymap ivy-switch-buffer-map))))
 #+END_SRC