emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/vc.el


From: Andre Spiegel
Subject: [Emacs-diffs] Changes to emacs/lisp/vc.el
Date: Tue, 16 Jul 2002 13:47:34 -0400

Index: emacs/lisp/vc.el
diff -c emacs/lisp/vc.el:1.331 emacs/lisp/vc.el:1.332
*** emacs/lisp/vc.el:1.331      Wed Mar  6 08:51:28 2002
--- emacs/lisp/vc.el    Tue Jul 16 13:47:33 2002
***************
*** 6,12 ****
  ;; Maintainer: Andre Spiegel <address@hidden>
  ;; Keywords: tools
  
! ;; $Id: vc.el,v 1.331 2002/03/06 13:51:28 gerd Exp $
  
  ;; This file is part of GNU Emacs.
  
--- 6,12 ----
  ;; Maintainer: Andre Spiegel <address@hidden>
  ;; Keywords: tools
  
! ;; $Id: vc.el,v 1.332 2002/07/16 17:47:33 spiegel Exp $
  
  ;; This file is part of GNU Emacs.
  
***************
*** 1107,1115 ****
        ;; Check relation of buffer and file, and make sure
        ;; user knows what he's doing.  First, finding the file
        ;; will check whether the file on disk is newer.
!       (if vc-dired-mode
!         (find-file-other-window file)
!       (set-buffer (find-file-noselect file)))
        (if (not (verify-visited-file-modtime (current-buffer)))
          (if (yes-or-no-p "Replace file on disk with buffer contents? ")
              (write-file (buffer-file-name))
--- 1107,1118 ----
        ;; Check relation of buffer and file, and make sure
        ;; user knows what he's doing.  First, finding the file
        ;; will check whether the file on disk is newer.
!       (set-buffer visited)
!       ;; ignore buffer-read-only during this test
!       (let ((buffer-read-only (not (file-writable-p file))))
!         (if vc-dired-mode
!             (find-file-other-window file)
!           (find-file-noselect file)))
        (if (not (verify-visited-file-modtime (current-buffer)))
          (if (yes-or-no-p "Replace file on disk with buffer contents? ")
              (write-file (buffer-file-name))
***************
*** 1224,1232 ****
--- 1227,1237 ----
              (yes-or-no-p (concat "File has unlocked changes.  "
                                   "Claim lock retaining changes? ")))
            (progn (vc-call steal-lock file)
+                    (clear-visited-file-modtime)
                   ;; Must clear any headers here because they wouldn't
                   ;; show that the file is locked now.
                   (vc-clear-headers file)
+                  (write-file (buffer-file-name))
                   (vc-mode-line file))
          (if (not (yes-or-no-p
                    "Revert to checked-in version, instead? "))
***************
*** 3249,3255 ****
  These bindings are added to the global keymap when you enter this mode:
  \\[vc-next-action]            perform next logical version-control operation 
on current file
  \\[vc-register]               register current file
- \\[vc-toggle-read-only]               like next-action, but won't register 
files
  \\[vc-insert-headers]         insert version-control headers in current file
  \\[vc-print-log]              display change history of current file
  \\[vc-revert-buffer]          revert buffer to latest version
--- 3254,3259 ----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]