Useful Commands
Initial check-out
cvs co -r
branch_name module_name
Protip: the -r specifies that you want to checkout from a tag/branch.
Branching
cvs tag -b
branch_name
Get latest
cvs up -Pd
Protip: the P prunes empty directories and the d will cause directories to be created as needed.
Commit / check-in changes
cvs commit
Protip: Always do a cvs up before you commit. Running cvs up will automatically merge if needed. Then you can view the merge (if one occured) and manually disposition it.
Adding /removing a file
cvs add file.txt
cvs delete file.txt
Protip: After adding or deleting a file you must commit the change in order for it to be visible to other users.
Checking differences against a branch
cvs diff -r
branch_name
Protip: In my opinion, using Tortoise CVS with WinMerge is much easier than the command line cvs diff tool.
Merging a branch
cvs up -j
branch_name -Pd
Protip: the j is what actually causes the merge to happen (merges changes made between working directory and the branch you provide).
When all else fails
cvs --help-options
cvs up --help-options
cvs co --help-options
cvs diff --help-options
What the letters mean when doing a CVS update
U - updated successfully
A - added but not yet committed (need to run a cvs commit)
R - removed but not yet committed (need to run a cvs commit)
M - modified in your working directory: the file in the repository was changed and your working directory file was older than the last time
CVS checked it OR the repository had changes which the system could safely merge
C - there was a conflict between the repository copy and your copy which requires human intervention
? - the file is in your working directory but not the repository and
CVS doesn't know what to do with it
The format of CVSROOT
The CVSROOT is basically your connection string to the source repository. These are your credentials to login to
CVS. The CVSROOT is in this format:
:pserver:
username@
computer_name:
repository
Downloads
Tortoise
CVS - a Windows shell integration interface for
CVS
http://www.tortoisecvs.org/
WinMerge - a diff utility. Integrates with Tortoise
http://winmerge.org/