comparison lisp/vc.el @ 31520:f9d2d484e1e2

* vc-sccs.el (vc-sccs-register): * vc-rcs.el (vc-rcs-register): * vc-cvs.el (vc-cvs-register): Don't clear file's properties. * vc.el (vc-register): Clear file's properties.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Sat, 09 Sep 2000 00:48:41 +0000
parents 5d331e68ac84
children de4e73d77734
comparison
equal deleted inserted replaced
31519:5a14247e8e26 31520:f9d2d484e1e2
1016 ;;; These functions help the vc-next-action entry point 1016 ;;; These functions help the vc-next-action entry point
1017 1017
1018 ;;;###autoload 1018 ;;;###autoload
1019 (defun vc-register (&optional set-version comment) 1019 (defun vc-register (&optional set-version comment)
1020 "Register the current file into a version control system. 1020 "Register the current file into a version control system.
1021 With prefix argument SET-VERSION, allow user to specify initial version 1021 With prefix argument SET-VERSION, allow user to specify initial version
1022 level. If COMMENT is present, use that as an initial comment. 1022 level. If COMMENT is present, use that as an initial comment.
1023 1023
1024 The version-control system to use is found by cycling through the list 1024 The version control system to use is found by cycling through the list
1025 `vc-handled-backends'. The first backend in that list which declares 1025 `vc-handled-backends'. The first backend in that list which declares
1026 itself responsible for the file (usually because other files in that 1026 itself responsible for the file (usually because other files in that
1027 directory are already registered under that backend) will be used to 1027 directory are already registered under that backend) will be used to
1028 register the file. If no backend declares itself responsible, the 1028 register the file. If no backend declares itself responsible, the
1029 first backend that could register the file is used." 1029 first backend that could register the file is used."
1051 (or comment (not vc-initial-comment)) 1051 (or comment (not vc-initial-comment))
1052 "Enter initial comment." 1052 "Enter initial comment."
1053 (lambda (file rev comment) 1053 (lambda (file rev comment)
1054 (message "Registering %s... " file) 1054 (message "Registering %s... " file)
1055 (let ((backend (vc-responsible-backend file))) 1055 (let ((backend (vc-responsible-backend file)))
1056 (vc-file-clearprops file)
1056 (vc-call-backend backend 'register file rev comment) 1057 (vc-call-backend backend 'register file rev comment)
1057 (vc-file-setprop file 'vc-backend backend) 1058 (vc-file-setprop file 'vc-backend backend)
1058 (unless vc-make-backup-files 1059 (unless vc-make-backup-files
1059 (make-local-variable 'backup-inhibited) 1060 (make-local-variable 'backup-inhibited)
1060 (setq backup-inhibited t))) 1061 (setq backup-inhibited t)))