aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndré Spiegel1995-08-17 13:08:36 +0000
committerAndré Spiegel1995-08-17 13:08:36 +0000
commit9341ff29bce91c62aab8b7714e92ec3eee6fac0c (patch)
tree4683e04530bc5ff126cc555f21f879b1aaa15e0b
parentc8de1d91120419d2cd185a7ed8c94693e70c7bd0 (diff)
downloademacs-9341ff29bce91c62aab8b7714e92ec3eee6fac0c.tar.gz
emacs-9341ff29bce91c62aab8b7714e92ec3eee6fac0c.zip
(vc-next-action-on-file): Query when trying to lock non-latest
version.
-rw-r--r--lisp/vc.el10
1 files changed, 9 insertions, 1 deletions
diff --git a/lisp/vc.el b/lisp/vc.el
index b22cd6fcdb6..01d2f993cfb 100644
--- a/lisp/vc.el
+++ b/lisp/vc.el
@@ -531,7 +531,15 @@ to an optional list of FLAGS."
531 (concat "-b" rev))) 531 (concat "-b" rev)))
532 (vc-checkout file nil rev)) 532 (vc-checkout file nil rev))
533 (error "Sorry, this is not implemented for SCCS.")) 533 (error "Sorry, this is not implemented for SCCS."))
534 (vc-checkout-writable-buffer file)))) 534 (if (vc-latest-on-branch-p file)
535 (vc-checkout-writable-buffer file)
536 (if (yes-or-no-p
537 "This is not the latest version. Really lock it? ")
538 (vc-checkout-writable-buffer file)
539 (if (yes-or-no-p "Lock the latest version instead? ")
540 (vc-checkout-writable-buffer file
541 (vc-branch-part (vc-workfile-version file))))))
542 )))
535 543
536 ;; a checked-out version exists, but the user may not own the lock 544 ;; a checked-out version exists, but the user may not own the lock
537 ((and (not (eq vc-type 'CVS)) ;There are no locks in CVS. 545 ((and (not (eq vc-type 'CVS)) ;There are no locks in CVS.