]> git.eshelyaron.com Git - emacs.git/commitdiff
(vc-rename-file): After renaming, update VC info and modeline.
authorRichard M. Stallman <rms@gnu.org>
Mon, 13 May 1996 01:31:28 +0000 (01:31 +0000)
committerRichard M. Stallman <rms@gnu.org>
Mon, 13 May 1996 01:31:28 +0000 (01:31 +0000)
Preserve buffer-read-only.

lisp/vc.el

index 1f649bf6abfac5d0bb0082d4ca5032bb84850e57..190cdc254be2792d548cf336d0a8c0321c9f5059 100644 (file)
@@ -1727,7 +1727,10 @@ A prefix argument means do not revert the buffer afterwards."
     (if oldbuf
        (save-excursion
          (set-buffer oldbuf)
-         (set-visited-file-name new)
+         (let ((buffer-read-only buffer-read-only))
+           (set-visited-file-name new))
+         (vc-backend new)
+         (vc-mode-line new)
          (set-buffer-modified-p nil))))
   ;; This had FILE, I changed it to OLD. -- rms.
   (vc-backend-dispatch old