22.214.171.124 Basic Version Control with Locking
On a locking-based version control system (such as SCCS, and RCS in
its default mode), C-x v v does the following:
- If there is more than one file in the VC fileset and the files have
inconsistent version control statuses, signal an error.
- If each file in the VC fileset is not registered with a version
control system, register the VC fileset. See Registering. If
Emacs cannot find a system to register under, it prompts for a
repository type, creates a new repository, and registers the VC
fileset with it.
- If each file is registered and unlocked, lock it and make it writable,
so that you can begin to edit it.
- If each file is locked by you and contains changes, commit the
changes. To do this, Emacs pops up a *vc-log* buffer; type the
desired log entry for the new revision, followed by C-c C-c to
commit (see Log Buffer).
- If each file is locked by you, but you have not changed it, release
the lock and make the file read-only again.
- If each file is locked by another user, ask whether you want to
“steal the lock”. If you say yes, the file becomes locked by you,
and a warning message is sent to the user who had formerly locked the
These rules also apply when you use CVS in locking mode, except
that CVS does not support stealing locks.