Prevent eshell from switching to existing eshell
Prevent duplicate eshell buffers as a result of quitting a second eshell buffer.
This commit is contained in:
parent
d402c6ef44
commit
e9c97d7ad0
1 changed files with 2 additions and 0 deletions
|
@ -24,6 +24,8 @@
|
||||||
(defun +eshell--bury-buffer (&optional dedicated-p)
|
(defun +eshell--bury-buffer (&optional dedicated-p)
|
||||||
(unless (switch-to-prev-buffer nil 'bury)
|
(unless (switch-to-prev-buffer nil 'bury)
|
||||||
(switch-to-buffer (doom-fallback-buffer)))
|
(switch-to-buffer (doom-fallback-buffer)))
|
||||||
|
(when (eq major-mode 'eshell-mode)
|
||||||
|
(switch-to-buffer (doom-fallback-buffer)))
|
||||||
(when +eshell-enable-new-shell-on-split
|
(when +eshell-enable-new-shell-on-split
|
||||||
(when-let* ((win (get-buffer-window (+eshell/open t))))
|
(when-let* ((win (get-buffer-window (+eshell/open t))))
|
||||||
(set-window-dedicated-p win dedicated-p))))
|
(set-window-dedicated-p win dedicated-p))))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue