CVS stands for Concurrent Versions System; it is a system
to keep in sync a set of files, put in a hierarchical directory tree.
People can update their local copy of the hierarchy tree from the
CVS server, and send back modifications or new files; or also
delete old files.
Its client-server based behaviour makes it multi-user,
and network enabled. That characteristic makes CVS the tool of choice
for projects where several people from distan places have to work together
on data files, specially programs source code.
All important free software projects use CVS as the central point between
the programmers to integrate their improvements and changes: Gnome, KDE,
The GIMP, Wine, etc.
And of course so does MandrakeSoft too for its own developments.
|
To use the CVS you need to connect to the server, and make a local copy
of the CVS module you want. The next times you would need only to do
an update to get the differences from your last connection.
It is easy. You only need the cvs package (which comes with the
standard Mandrake distribution) and enough disk space for what you want
to get.
To tell cvs to which server you want to connect, under which
identity, and what CVS head you want; you have to define the
CVSROOT variable, like this:
export CVSROOT=:pserver:anoncvs@linux-mandrake.com:/home/cvs/cooker
if you want to connect to server linux-mandrake.com, identify
yourself to server as anoncvs, and make the requests relatives
to the CVS head /home/cvs/cooker (there can be more than one
on a given server).
Once you have set that variable you can connect yoursel; that is done
by the cvs login command.
You then will be prompted for your password, and voilą! your are connected.
The next step is only necessary the first time; you need to create
a fresh copy of the hierarchy you want. Say you want to get the
po hierarchy tree, you can type:
cvs -z3 checkout po
(the -zX means to use compression; as what is exchanged are mainly plain
text files it is useful; you can use a bigger number to get more compression,
or a lower one to get less. Note however that more compressions means also
that your cpu and the one on the server will be more loaded)
You will see a lot of messages on stdout, as files are get and copied
on your local disc.
The next time you don't need to do a cvs checkout anymore; just a cvs login
(don't forget the CVSROOT environment variable), then a cvs upgrade, like
this:
cd po
cvs -z3 upgrade -d
Note that I changed to the po directory; the I find it easier that way.
the -d means to create and get any new directory that the CVS server could
have created since your last visit. The -zX has the same meaning as in
cvs checkout
Now with those simple commands you can allways get the lastest snapshots
of any project that you have read CVS access to.
Don't abuse of it however; it uses a lot of bandwith and server ressources
to put such a service in place; if you don't have any use to get the
program sources don't do it. On the other hand, if you are serious at
contributing back to the free software world (and you don't need to be
a programmer for that; there is currently cruel need fro translators, writers,
graphic artistsc,...) you have the tools needed to get the files before
their official release and the possibility to send your suggestions,
improvements, etc.
If you have a write access to the CVS you can also directly send your
changes up.
There three kind of modifications you can do:
- modifications of existing files:just change the file (edit it,
or copy another one over it etc).
- add new files/dirs:You need to copy them (or create them for
directories) then call cvs add newfileordir to tell
you want to add a new entry.
- remove files/dirs:You need to first remove them locally, then
call cvs delete removedfileordir (yes, it is a little annoying,
as you can't use completion or shell special chars *? in the
cvs delete command line (as you can do with cvs add for exemple)
Then, you type cvs -z3 commit (again the -zX has the habitual meaning)
and only then the changes you made will be commited to the server.
You will be faced to your favorite editor (defined with the EDITOR
environment variable) to write som description of what your modifications
are about (that will be kept on the CVS server logs and would allow
easier fallback in case of problems)
Note that if the server has newer version of files than you try to commit
an error will happen; so it is recommended that you do a cvs update
prior of anything.
Currently available CVS modules at mandrake-linux.com
- po: which gives access to the translations of the descriptions used
for the rpm packages (you can connect anonymously with login anoncvs
and password cvs; if you want a write access ask to
Chmouel Boudjna)
- .... (this page isn't finished yet :) )
|