[Fix #798] Prompt for confirmation in prelude-kill-other-buffers
This commit is contained in:
parent
2a386116f1
commit
dc861b7c8b
1 changed files with 6 additions and 5 deletions
|
@ -357,11 +357,12 @@ Repeated invocations toggle between the two most recently open buffers."
|
|||
"Kill all buffers but the current one.
|
||||
Doesn't mess with special buffers."
|
||||
(interactive)
|
||||
(-each
|
||||
(->> (buffer-list)
|
||||
(-filter #'buffer-file-name)
|
||||
(--remove (eql (current-buffer) it)))
|
||||
#'kill-buffer))
|
||||
(when (y-or-n-p "Are you sure you want to kill all buffers but the current one? ")
|
||||
(-each
|
||||
(->> (buffer-list)
|
||||
(-filter #'buffer-file-name)
|
||||
(--remove (eql (current-buffer) it)))
|
||||
#'kill-buffer)))
|
||||
|
||||
(defun prelude-create-scratch-buffer ()
|
||||
"Create a new scratch buffer."
|
||||
|
|
Loading…
Reference in a new issue