Function: vc-sccs-revert

vc-sccs-revert is a byte-compiled function defined in vc-sccs.el.gz.

Signature

(vc-sccs-revert FILE &optional CONTENTS-DONE)

Documentation

Revert FILE to the version it was based on.

If FILE is a directory, revert all subfiles.

Source Code

;; Defined in /usr/src/emacs/lisp/vc/vc-sccs.el.gz
(defun vc-sccs-revert (file &optional _contents-done)
  "Revert FILE to the version it was based on.
If FILE is a directory, revert all subfiles."
  (if (file-directory-p file)
      (mapc #'vc-sccs-revert (vc-expand-dirs (list file) 'SCCS))
    (vc-sccs-do-command nil 0 "unget" (vc-master-name file))
    (vc-sccs-do-command nil 0 "get" (vc-master-name file))
    ;; Checking out explicit revisions is not supported under SCCS, yet.
    ;; We always "revert" to the latest revision; therefore
    ;; vc-working-revision is cleared here so that it gets recomputed.
    (vc-file-setprop file 'vc-working-revision nil)))