mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-31 14:43:40 -05:00
Bind ZX -> Save then kill current buffer
Since bury-buffer is already on SPC b z, and isn't a common operation in day to day Emacs use. Other useful keybinds: ZZ -> Save then kill current window zx -> kill current buffer (prompts if unsaved) SPC b z -> bury buffer zn -> (operator) narrow buffer zN -> widen narrowed buffer
This commit is contained in:
@@ -264,6 +264,13 @@ See `doom-real-buffer-p' for an explanation for real buffers."
|
||||
;;
|
||||
;; Interactive commands
|
||||
|
||||
;;;###autoload
|
||||
(defun doom/save-and-kill-buffer ()
|
||||
"Save the current buffer to file, then kill it."
|
||||
(interactive)
|
||||
(save-buffer)
|
||||
(kill-current-buffer))
|
||||
|
||||
;;;###autoload
|
||||
(defun doom/kill-this-buffer-in-all-windows (buffer &optional dont-save)
|
||||
"Kill BUFFER globally and ensure all windows previously showing this buffer
|
||||
|
Reference in New Issue
Block a user