• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/emacs-92/emacs/lisp/

Lines Matching +defs:vc +defs:registered

0 ;;; vc-sccs.el --- support for SCCS version-control
6 ;; Author: FSF (see vc.el for full credits)
33 (require 'vc))
39 (defcustom vc-sccs-register-switches nil
42 \\[vc-sccs-register]."
49 :group 'vc)
51 (defcustom vc-sccs-diff-switches nil
60 :group 'vc)
62 (defcustom vc-sccs-header (or (cdr (assoc 'SCCS vc-header-alist)) '("%W%"))
63 "*Header keywords to be inserted by `vc-insert-headers'."
65 :group 'vc)
68 (defcustom vc-sccs-master-templates
69 '("%sSCCS/s.%s" "%ss.%s" vc-sccs-search-project-dir)
71 For a description of possible values, see `vc-check-master-templates'."
73 ("%sSCCS/s.%s" "%ss.%s" vc-sccs-search-project-dir))
78 :group 'vc)
86 (defconst vc-sccs-name-assoc-file "VC-names")
94 ;;; The autoload cookie below places vc-sccs-registered directly into
95 ;;; loaddefs.el, so that vc-sccs.el does not need to be loaded for
99 ;;;###autoload (defun vc-sccs-registered(f) (vc-default-registered 'SCCS f))
100 (defun vc-sccs-registered (f) (vc-default-registered 'SCCS f))
102 (defun vc-sccs-state (file)
105 (if (vc-insert-file (vc-sccs-lock-file file))
106 (let* ((locks (vc-sccs-parse-locks))
107 (workfile-version (vc-workfile-version file))
110 (if (vc-workfile-unchanged-p file)
113 (if (string= locking-user (vc-user-login-name file))
118 (defun vc-sccs-state-heuristic (file)
120 (if (not (vc-mistrust-permissions file))
138 (vc-sccs-state file))))
139 (vc-sccs-state file)))
141 (defun vc-sccs-workfile-version (file)
142 "SCCS-specific version of `vc-workfile-version'."
148 (vc-insert-file (vc-name file) "^\001e\n\001[^s]")
149 (vc-parse-buffer "^\001d D \\([^ ]+\\)" 1)))
151 (defun vc-sccs-checkout-model (file)
152 "SCCS-specific version of `vc-checkout-model'."
155 (defun vc-sccs-workfile-unchanged-p (file)
156 "SCCS-specific implementation of `vc-workfile-unchanged-p'."
157 (zerop (apply 'vc-do-command nil 1 "vcdiff" (vc-name file)
159 (concat "-r" (vc-workfile-version file))))))
167 (defun vc-sccs-register (file &optional rev comment)
172 `vc-register-switches' and `vc-sccs-register-switches' are passed to
176 expanded if `vc-keep-workfiles' is non-nil, otherwise, delete the workfile."
179 (project-file (vc-sccs-search-project-dir dirname basename)))
180 (let ((vc-name
182 (format (car vc-sccs-master-templates) dirname basename))))
183 (apply 'vc-do-command nil 0 "admin" vc-name
188 (vc-switches 'SCCS 'register)))
190 (if vc-keep-workfiles
191 (vc-do-command nil 0 "get" (vc-name file)))))
193 (defun vc-sccs-responsible-p (file)
195 ;; TODO: check for all the patterns in vc-sccs-master-templates
197 (stringp (vc-sccs-search-project-dir (or (file-name-directory file) "")
200 (defun vc-sccs-checkin (file rev comment)
201 "SCCS-specific version of `vc-backend-checkin'."
202 (apply 'vc-do-command nil 0 "delta" (vc-name file)
205 (vc-switches 'SCCS 'checkin))
206 (if vc-keep-workfiles
207 (vc-do-command nil 0 "get" (vc-name file))))
209 (defun vc-sccs-find-version (file rev buffer)
210 (apply 'vc-do-command
211 buffer 0 "get" (vc-name file)
216 (vc-sccs-lookup-triple file rev)))
217 (vc-switches 'SCCS 'checkout)))
219 (defun vc-sccs-checkout (file &optional editable rev)
227 ;; Change buffers to get local value of vc-checkout-switches.
229 (setq switches (vc-switches 'SCCS 'checkout))
242 (apply 'vc-do-command nil 0 "get" (vc-name file)
244 (and rev (concat "-r" (vc-sccs-lookup-triple file rev)))
248 (defun vc-sccs-revert (file &optional contents-done)
250 (vc-do-command nil 0 "unget" (vc-name file))
251 (vc-do-command nil 0 "get" (vc-name file))
254 ;; vc-workfile-version is cleared here so that it gets recomputed.
255 (vc-file-setprop file 'vc-workfile-version nil))
257 (defun vc-sccs-cancel-version (file editable)
260 (vc-do-command nil 0 "rmdel"
261 (vc-name file)
262 (concat "-r" (vc-workfile-version file)))
263 (vc-do-command nil 0 "get"
264 (vc-name file)
267 (defun vc-sccs-steal-lock (file &optional rev)
269 (vc-do-command nil 0 "unget" (vc-name file) "-n" (if rev (concat "-r" rev)))
270 (vc-do-command nil 0 "get" (vc-name file) "-g" (if rev (concat "-r" rev))))
278 (defun vc-sccs-print-log (file &optional buffer)
280 (vc-do-command buffer 0 "prs" (vc-name file)))
282 (defun vc-sccs-logentry-check ()
288 (defun vc-sccs-diff (file &optional oldvers newvers buffer)
290 (setq oldvers (vc-sccs-lookup-triple file oldvers))
291 (setq newvers (vc-sccs-lookup-triple file newvers))
292 (apply 'vc-do-command (or buffer "*vc-diff*") 1 "vcdiff" (vc-name file)
296 (vc-switches 'SCCS 'diff))))
304 (defun vc-sccs-assign-name (file name)
306 (vc-sccs-add-triple name file (vc-workfile-version file)))
314 (defun vc-sccs-check-headers ()
320 (defun vc-sccs-rename-file (old new)
321 ;; Move the master file (using vc-rcs-master-templates).
322 (vc-rename-master (vc-name old) new vc-sccs-master-templates)
326 (expand-file-name vc-sccs-name-assoc-file
327 (file-name-directory (vc-name old))))
343 ;; a (autoload 'vc-sccs-search-project-dir "vc-sccs") which would not
344 ;; help us avoid loading vc-sccs.
346 (progn (defun vc-sccs-search-project-dir (dirname basename)
363 (defun vc-sccs-lock-file (file)
365 (let ((master (vc-name file)))
371 (defun vc-sccs-parse-locks ()
383 (defun vc-sccs-add-triple (name file rev)
386 (expand-file-name vc-sccs-name-assoc-file
387 (file-name-directory (vc-name file))))
393 (defun vc-sccs-lookup-triple (file name)
401 (vc-insert-file
402 (expand-file-name vc-sccs-name-assoc-file
403 (file-name-directory (vc-name file))))
404 (vc-parse-buffer (concat name "\t:\t" file "\t\\(.+\\)") 1))))
406 (provide 'vc-sccs)
409 ;;; vc-sccs.el ends here