Prev | Current Page 1429 | Next

Christopher Negus

"Linux Bible, 2008 Edition: Boot up to Ubuntu, Fedora, KNOPPIX, Debian, openSUSE, and 11 Other Distributions"

To keep the discussion simple, however, the example in this chapter deals only
with a repository accessed locally. The following steps resemble the process described earlier for
RCS, but they are slightly more involved and obviously use CVS concepts:
1. Create a CVS repository:
$ mkdir /space/cvs
$ export CVSROOT=/space/cvs
$ cvs init
The first command creates a directory named /space/cvs in which to establish the
repository. The second command defines the environment variable $CVSROOT with this
directory. Defining $CVSROOT makes using CVS much simpler. The third command initializes
the repository, which creates some administrative directories CVS needs to work
properly.
2. Create a top-level working directory in which to store your various projects and then
change into this directory:
$ mkdir projects
$ cd projects
3. Check out a copy of the CVS root directory into the directory you just created:
$ cvs -d $CVSROOT co -l .
cvs checkout: Updating .
The -d option tells cvs the name of the directory containing the CVS repository
($CVSROOT, or /space/cvs); co means check out (just as with RCS); the -l option,
which stands for local, means to work only in the current directory rather than recursing
through subdirectories; and the . specifies the current directory.


Pages:
1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441