Subject: Re: bug#28121: 26.0.50; vc-dir doesn't update when conflict resolved

From: Dmitry Gutov <[email-masked]>
Date: Sun, 20 Aug 2017 23:59:43 +0300

Hi Tom!

On 8/17/17 3:36 PM, Tom Tromey wrote:
> 
> I have a vc-dir buffer opened for my project.
> I did a "git rebase" (externally) which resulted in a merge conflict.
> I typed "g" in the vc-dir buffer to refresh.
> 
> vc-dir showed me which files were in conflict.
> 
> I edited one of the files, and upon saving, I expected emacs to refresh
> the file's state in the vc-dir buffer, to reflect that the file was no
> longer in conflict.

Thanks for the report. I don't have time now to repro, but please try 
the following patch. Maybe add a third t to the arguments list if it 
doesn't help.

diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el
index cc3e295..6123b32 100644
--- a/lisp/vc/vc-git.el
+++ b/lisp/vc/vc-git.el
@@ -964,6 +964,7 @@ vc-git-resolve-when-done
                                                  (vc-git-root 
buffer-file-name)))
                 (vc-git-conflicted-files (vc-git-root buffer-file-name)))
          (vc-git-command nil 0 nil "reset"))
+      (vc-resynch-buffer buffer-file-name t t)
        ;; Remove the hook so that it is not called multiple times.
        (remove-hook 'after-save-hook 'vc-git-resolve-when-done t))))