[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v
From: |
Eric S. Raymond |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v |
Date: |
Fri, 02 May 2008 17:47:30 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Eric S. Raymond <esr> 08/05/02 17:47:26
Index: vc-cvs.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/vc-cvs.el,v
retrieving revision 1.127
retrieving revision 1.128
diff -u -b -r1.127 -r1.128
--- vc-cvs.el 2 May 2008 07:38:11 -0000 1.127
+++ vc-cvs.el 2 May 2008 17:47:23 -0000 1.128
@@ -35,6 +35,30 @@
;; new functions when we reload this file.
(put 'CVS 'vc-functions nil)
+;;; Properties of the backend.
+
+(defun vc-cvs-revision-granularity () 'file)
+
+(defun vc-cvs-checkout-model (files)
+ "CVS-specific version of `vc-checkout-model'."
+ (if (getenv "CVSREAD")
+ 'announce
+ (let* ((file (if (consp files) (car files) files))
+ (attrib (file-attributes file)))
+ (or (vc-file-getprop file 'vc-checkout-model)
+ (vc-file-setprop
+ file 'vc-checkout-model
+ (if (and attrib ;; don't check further if FILE doesn't exist
+ ;; If the file is not writable (despite CVSREAD being
+ ;; undefined), this is probably because the file is being
+ ;; "watched" by other developers.
+ ;; (If vc-mistrust-permissions was t, we actually shouldn't
+ ;; trust this, but there is no other way to learn this from
+ ;; CVS at the moment (version 1.9).)
+ (string-match "r-..-..-." (nth 8 attrib)))
+ 'announce
+ 'implicit))))))
+
;;;
;;; Customization options
;;;
@@ -238,26 +262,6 @@
(vc-cvs-registered file)
(vc-file-getprop file 'vc-working-revision))
-(defun vc-cvs-checkout-model (files)
- "CVS-specific version of `vc-checkout-model'."
- (if (getenv "CVSREAD")
- 'announce
- (let* ((file (if (consp files) (car files) files))
- (attrib (file-attributes file)))
- (or (vc-file-getprop file 'vc-checkout-model)
- (vc-file-setprop
- file 'vc-checkout-model
- (if (and attrib ;; don't check further if FILE doesn't exist
- ;; If the file is not writable (despite CVSREAD being
- ;; undefined), this is probably because the file is being
- ;; "watched" by other developers.
- ;; (If vc-mistrust-permissions was t, we actually shouldn't
- ;; trust this, but there is no other way to learn this from
- ;; CVS at the moment (version 1.9).)
- (string-match "r-..-..-." (nth 8 attrib)))
- 'announce
- 'implicit))))))
-
(defun vc-cvs-mode-line-string (file)
"Return string for placement into the modeline for FILE.
Compared to the default implementation, this function does two things:
@@ -393,7 +397,7 @@
(if (and (file-exists-p file) (not rev))
;; If no revision was specified, just make the file writable
;; if necessary (using `cvs-edit' if requested).
- (and editable (not (eq (vc-cvs-checkout-model file) 'implicit))
+ (and editable (not (eq (vc-cvs-checkout-model (list file)) 'implicit))
(if vc-cvs-use-edit
(vc-cvs-command nil 0 file "edit")
(set-file-modes file (logior (file-modes file) 128))
@@ -421,7 +425,7 @@
(defun vc-cvs-revert (file &optional contents-done)
"Revert FILE to the working revision on which it was based."
(vc-default-revert 'CVS file contents-done)
- (unless (eq (vc-cvs-checkout-model file) 'implicit)
+ (unless (eq (vc-cvs-checkout-model (list file)) 'implicit)
(if vc-cvs-use-edit
(vc-cvs-command nil 0 file "unedit")
;; Make the file read-only by switching off all w-bits
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/01
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/01
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/01
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/02
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v,
Eric S. Raymond <=
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Glenn Morris, 2008/05/06
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/07
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/09
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/10
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/15
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/16
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/16
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Eric S. Raymond, 2008/05/16
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Dan Nicolaescu, 2008/05/26
- [Emacs-diffs] Changes to emacs/lisp/vc-cvs.el,v, Stefan Monnier, 2008/05/30