From 91bc775b0c60342f118640001d2ce293d4f1f7ef Mon Sep 17 00:00:00 2001 From: Dmitry Gutov Date: Wed, 3 Jan 2024 02:11:56 +0200 Subject: [PATCH] (vc-deduce-fileset): Handle log-view-mode derivatives specially * lisp/vc/vc.el (vc-deduce-fileset): Handle log-view-mode derivatives specially, that helps after switching projects (bug#68174). --- lisp/vc/vc.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 69097c180f2..7b2301ee3e5 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -1074,6 +1074,7 @@ Within directories, only files already under version control are noticed." (defvar vc-dir-backend) (defvar log-view-vc-backend) +(defvar log-view-vc-fileset) (defvar log-edit-vc-backend) (defvar diff-vc-backend) (defvar diff-vc-revisions) @@ -1155,6 +1156,8 @@ BEWARE: this function may change the current buffer." (vc-state buffer-file-name) (vc-checkout-model backend buffer-file-name)) (list backend (list buffer-file-name)))) + ((derived-mode-p 'log-view-mode) + (list log-view-vc-backend log-view-vc-fileset)) ((and (buffer-live-p vc-parent-buffer) ;; FIXME: Why this test? --Stef (or (buffer-file-name vc-parent-buffer) -- 2.39.2