fix(magit): don't auto-revert non-file-visiting buffers

Fix: #8339
Amend: 17a870fef8
This commit is contained in:
Henrik Lissner
2025-04-05 02:02:00 -04:00
parent 457b7cab1e
commit a13fda7ec0

View File

@ -104,7 +104,7 @@ window that already exists in that direction. It will split otherwise."
(when (magit-auto-revert-repository-buffer-p buffer)
(when (bound-and-true-p vc-mode)
(vc-refresh-state))
(unless (buffer-modified-p buffer)
(when (and buffer-file-name (not (buffer-modified-p buffer)))
(revert-buffer t t t))
(force-mode-line-update))))