Datasheet

“main” (Installation and Administration) 2004/6/25 13:29 page 564 #590
i
i
i
i
i
i
i
i
23.4.1 Configuring a CVS Server
The server is the host on which all valid files are located, including the latest
versions of all files. Any stationary workstation can be used as a server. If
possible, the data of the CVS repository should be included in regular back-
ups.
When configuring a CVS server, it might be a good idea to grant users ac-
cess to the server via SSH. If the user is known to the server as tux and the
CVS software is installed on the server as well as on the client, the follow-
ing environment variables must be set on the client side:
CVS_RSH=ssh CVS_ROOT=tux@server:/serverdir
The command cvs init can be used to initialize the CVS server from the
client side. This needs to be done only once.
Finally, the synchronization must be assigned a name. Select or create a di-
rectory on the client exclusively to contain files to manage with CVS (the
directory can also be empty). The name of the directory is also the name
of the synchronization. In this example, the directory is called synchome.
Change to this directory and enter the following command to set the syn-
chronization name to synchome:
cvs import synchome tux wilber
Many CVS commands require a comment. For this purpose, CVS starts
an editor (the editor defined in the environment variable $EDITOR or vi
if no editor was defined). The editor call can be circumvented by entering
the comment in advance on the command line, such as in the following
example:
cvs import -m ’this is a test’ synchome tux wilber
23.4.2 Using CVS
The synchronization repository can now be checked out from all hosts with
cvs co synchome.
This creates a new subdirectory synchome on the client. To commit your
changes to the server, change to the directory synchome (or one of its sub-
directories) and enter cvs commit.
By default, all files (including subdirectories) are committed to the
server. To commit only individual files or directories, specify them
564 23.4. Introduction to CVS