Some hints for CVS
Starting CVS
Add the following line in .bashrc
export CVSROOT=~/CVSCreate the directory CVS
cd ~ mkdir CVSInitialise the CVS repository
cvs init
Importing an existing project
Move inside the project directory
cd Project cvs import -m "Initial import." PROJECT user startRemove the project directory
cd .. rm -rf ProjectDefine a module for the new project
cvs checkout CVSROOT/modules cd CVSROOTEdit the
modules file adding the following line at the end
project PROJECTCommit this change
cvs commit -m "Added the project module." modules cd .. cvs release -d CVSROOT
Adding and removing files
To add a file
cvs add fileIf the file contains binary data, specify
-kb
cvs add -kb fileCommit the addition
cvs commit -m "Added file." file
To remove a file
rm file cvs remove fileCommit the removal
cvs commit -m "Removed file." file
Tagging
It's possible to add a tag, so to have a symbolic name that references the current state of the repository
cvs tag release-1_0 file
To remove a tag
cvs tag -d release-1_0 file
Personal preferences
The file
.cvsrc in the home directory can be used to set options to commands. For example, to obtain unified diffs that show which C function the changes are in, add this line
diff -u -p