mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
vc-modify-change-comment: Revert Log View buffer
* lisp/vc/vc.el (vc-modify-change-comment): Revert the Log View buffer after modifying the change comment.
This commit is contained in:
parent
f33bc659c9
commit
9729353ba0
1 changed files with 11 additions and 1 deletions
|
|
@ -2517,7 +2517,17 @@ the variable `vc-BACKEND-header'."
|
|||
(lambda () (vc-call-backend backend 'log-edit-mode))
|
||||
(lambda (files comment)
|
||||
(vc-call-backend backend
|
||||
'modify-change-comment files rev comment))
|
||||
'modify-change-comment files rev comment)
|
||||
;; We are now back in `vc-parent-buffer'.
|
||||
;; If this is Log View, then revision IDs might now be
|
||||
;; out-of-date, which could be hazardous if the user immediately
|
||||
;; tries to use `log-view-modify-change-comment' a second time.
|
||||
;; E.g. with Git, `vc-git-modify-change-comment' could create an
|
||||
;; "amend!" commit referring to a commit which no longer exists
|
||||
;; on the branch, such that it wouldn't be autosquashed.
|
||||
;; So refresh the view.
|
||||
(when (derived-mode-p 'log-view-mode)
|
||||
(revert-buffer)))
|
||||
nil backend)))
|
||||
|
||||
;;;###autoload
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue