Created
September 27, 2011 06:29
-
-
Save puffnfresh/1244465 to your computer and use it in GitHub Desktop.
Emacs hook to only show current perspective's buffers in iswitchb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; For perspective.el: | |
;; https://github.com/nex3/perspective-el | |
(defun iswitchb-persp-curr-only () | |
(let* ((names (remq nil (mapcar 'buffer-name (persp-buffers persp-curr)))) | |
(matches (remove-if-not (lambda (x) (member x names)) iswitchb-temp-buflist))) | |
(setf iswitchb-temp-buflist matches))) | |
(add-hook 'iswitchb-make-buflist-hook 'iswitchb-persp-curr-only) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment