CVS
From Maslab 2011
Note that Subversion is a more powerful alternative to CVS; you should use it instead unless you have a good reason.
Setting up a CVS respository
- To set up a CVS repository for your team in your Athena locker:
-
mkdir ~/maslabcvs
(you can name it whatever you want) -
fs setacl -dir ~/maslabcvs -acl system:maslab-2009-team-N all
(where N is your team number; see Athena lists) -
setenv CVSROOT $HOME/maslabcvs
-
cvs init
- Change to the directory that contains your code. Make sure it contains only files/directories that you want to put in the repository.
-
cvs import modulename init head
(wheremodulename
is a name you pick)
-
- If one of your teammates has set up a repository for your team, do this:
-
attach teammate
(whereteammate
is the username of the person who made the repository) -
setenv CVSROOT /mit/teammate/maslabcvs
- If you put the previous two lines in your
.environment
file, you won't ever need to type them again. You might also want to setCVS_EDITOR
to your favorite text editor. It will be used for recording log messages when you commit.
-
Using CVS
- To checkout a copy of the code:
cvs co modulename
. - To update your copy to the latest version:
cvs up
. - To commit your changes:
cvs commit
(you must update before you can commit).