tools/magit: don't kill all magit buffers when quitting one

And mark all outdated buffers, rather than just the ones in the current
workgroup.
This commit is contained in:
Henrik Lissner 2019-08-28 15:22:14 -04:00
parent 7727920629
commit ccaf92b0d3
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -69,14 +69,13 @@
control in buffers." control in buffers."
(interactive) (interactive)
(quit-window) (quit-window)
(unless (cdr (unless (delq nil
(delq nil (mapcar (lambda (win)
(mapcar (lambda (win) (with-selected-window win
(with-selected-window win (eq major-mode 'magit-status-mode)))
(eq major-mode 'magit-status-mode))) (window-list)))
(window-list))))
(mapc #'+magit--kill-buffer (magit-mode-get-buffers)) (mapc #'+magit--kill-buffer (magit-mode-get-buffers))
(dolist (buffer (doom-buffer-list)) (dolist (buffer (buffer-list))
(when (buffer-live-p buffer) (when (buffer-live-p buffer)
(if (get-buffer-window buffer) (if (get-buffer-window buffer)
(+magit--refresh-vc-in-buffer buffer) (+magit--refresh-vc-in-buffer buffer)