next up previous contents
Next: Committing your changes Up: A Sample Session Previous: A Sample Session   Contents

Getting the Source

You need to know the location of the repository.

If the repository is local then you only need to know the path to the repository. Most open source projects share a repository with many widely separated developers so the repository is remote. In any case, the general form of the location looks like:

[:method:][[user][:pass]@]host[:[port]]/path
where: method (optional) is one of local, ext, server, or pserver. The local method is assumed if the method isn't specified. Note that most of this information is unnecessary to reach our local repository. In fact, we need only specify it as:
cvs -d /home/cvs

Projects will tell you that the CVS is located some particular site. For instance, we'll assume you are going to work on Axiom. Axiom's CVS is at: subversions.gnu.org:/cvsroot/axiom.

We want to get a copy of the files which involves 3 steps.

The first step is to set up a shell variable called CVSROOT. You also (usually) need a second shell variable called CVS_RSH which tells CVS which program to use to communicate. Lets assume that your userid on the Axiom site is ``bob'' So you would type:

export CVS\_RSH=ssh
export CVSROOT=:pserver:bob@subversions.gnu.org:/cvsroot/axiom
The second step is to login to the site thus:

cvs login
which will prompt you for a password. The third step is to ``checkout'' the code thus:
cd ~
cvs co axiom
and you end up with the whole axiom development tree of code in a directory called axiom.

If you don't have a userid on the system and just want to fetch the code as an anonymous user you can do:

cvs -d:pserver:anoncvs@subversions.gnu.org:/cvsroot/axiom co axiom


next up previous contents
Next: Committing your changes Up: A Sample Session Previous: A Sample Session   Contents
root 2004-02-24