NETS CVS Repository
A CVS repository is maintained on netserver for the purpose of tracking
revisions of configurations as well as software. This page provides a brief
introduction to using it.
View Files
The easiest way to view the repository is to use CVSWeb. The link http://netserver/cgi-bin/cvsweb/ will
take you to a web interface for viewing the repository. You will need to log
in to view the repository.
Getting Access
If you have an account on netserver, you can get direct access to the CVS
repository. Accessing the repository from netserver itself involves setting
a single environment variable, while remote access requires two. These can
of course be placed in an appropriate .bashrc or .profile startup file.
On a remote system:
> export CVSROOT=:ext:netserver:/usr/share/cvsroot
> export CVS_RSH=ssh
On netserver itself:
> export CVSROOT=/usr/share/cvsroot
Grabbing Files
Getting a module out of the repository is now a simple matter of:
>cvs co snmp
This checks out, for example, the snmp module. This command creates a new
directory named 'snmp' in the current directory containing the latest
revision of the files in the snmp module.
Updating Files
Often, the repository will be updated and you wish to update your local copy
of the files to match. This is done with the update command. It brings
changes from the repository to the local copy. The current directory should
be the module directory, or it's parent.
> cvs update
Another possibility is that you want to update the repository with changes
made locally. That is a matter of using the CVS commit command:
> cvs commit
Adding files
Adding a file to a module you've already checked out is easy. Just add and
commit.
> cvs add myfile.txt
> cvs commit
Adding new modules
To add a new module:
> cd (directory with files to add)
> cvs import module_name username start
This creates a new module named module_name containing the files in the
current directory. The 'username' and 'start' are just tags that CVS requires
but which we don't currently use.
Automatic comments
The commit and import commands will open a text editor so that you can provide
a log entry to be included. Use the -m option to specify the log entry on the
command line. This is useful for scripted commit's and such.
More Information
Read up at the CVS Home Page for lots
more information. This is just meant as the basic commands to get started.
Address comments or questions about this Web page to the
Network Engineering & Telecommunications Section
at
nets-www@ncar.ucar.edu.
The NETS is part of the
Computational & Information Systems Laboratory
of the
National Center for Atmospheric Research,
which is sponsored by the
National Science Foundation
and managed by the
University Corporation for Atmospheric Research.
This website follows the
UCAR General Privacy Policy
and the
NCAR/UCAR/UOP Terms of Use.