Cvs Tutorial

Some on-line ConcurrentVersionsSystem tutorials:

Per Cederqvist's manual
AKA TheCederqvist

Open Source Development with CVS by Karl Fogel (ISBN 1-57610-490-7 (Orig.); latest edition is ISBN 1932111204 )
AKA CvsBook

Frankly, if you're looking for a CVS tutorial/reference/bible you can't do much better than Karl Fogel's book. The online version of his printed book doesn't have musings on the nature of open source, but the CVS-specific chapters of the book are on-line and copyrighted under the GnuGeneralPublicLicense.

CVS BestPractice by The Linux Documentation Project

Quick and Dirty Guide to CVS - Learn CVS in 21 minutes!

CVS on RedHat 7.2

CVS on MacOsx There are some factual errors here. Not a good introduction for the novice. The CvsBook is better.

CVS for Windows
I found the download page hard to find, so here it is

Argh. And in fact, that's not the whole thing. What you want to do is go to and download the latest even-numbered zip (e.g.

How to set up a ConcurrentVersionsSystem repository on your own machine.

(Beware UnixCulturalAssumption; see

Initial Setup Do I have CVS installed on my machine?

Probably. Type cvs at your shell prompt and see. Type which cvs to see where it lives (this tutorial will assume it lives as /usr/local/cvs).

If you've never used cvs before, type the following to set it up initially.

 sudo mkdir /usr/local/cvsrep            # Make the repository.
 sudo chmod g+w /usr/local/cvsrep        # Group (usually wheel) can use the repository.
Cvs uses an environmental variable called CVSROOT to show the path to CVS. Edit your .bash_profile to include the following:

 export CVSROOT
Save your profile and load it.

To start CVS for the first time type:

 cvs -d /usr/local/cvsrep init           #If you haven't changed your .bash_profile.
 cvs init                                #If you have.

As a casual Unix user, I missed the whole "chgrp & chmod g+s" trick to get cvs additions to be available to everyone. This didn't seem to be covered well in the FAQs and other documentation. Maybe I missed something, or maybe native Unix users consider it obvious. It wasn't obvious to me. Initially I had all the CVS users in the same default group, now I know that's not necessary. Maybe there are some other not-so-obvious tricks, as well?

Here's a slightly more detailed explanation:

cvs creates files with the user as owner, and the user's default group as group. so if somebody else comes along, they can't get at those files unless they're in the same default group. Unless:

	chgrp PROJECTGROUP on the existing stuff	
	chmod g+s on the project directories
That way any files or directories created inside the project are in PROJECTGROUP, and the g+s propagates the group setting to new subdirectories. Now anyone in PROJECTGROUP has full access to existing and new files.

To do this to an already existing project tree:
 chgrp -R projgroup dir
 chmod -R g+w dir
 find dir -type d | xargs chmod g+s
Sometimes it is also feasible to make cvsroot's mode +t. But usually it's cleaner to just have separate repositories for all groups of users.

A very useful cvs command:

    cvs -nq up
shows you a status summary without changing anything.

View edit of June 25, 2013 or FindPage with title or text search