export CVSROOT=/home/cvs
export EDITOR=/bin/vi
3. If you wish to have files made read-only after checking them in, define:If omited the second line, vi will be the editor used by default.
bash# export CVSREAD=yes
bash# cvs -d $CVSROOT init
bash# groupadd cvs
# create cvs group
bash# useradd -g cvs -d $CVSROOT cvsbash# chgrp -R cvs $CVSROOT
bash# chmod o-rwx $CVSROOT
bash# chmod ug+rwx $CVSROOT
bash# usermod -G cvs your_user_name
bash# usermod -G cvs some_other_user
export CVSROOT=/home/cvsrepexport EDITOR=/bin/vi
bash$ newgrp cvsbash$ cd ~/YourAppDirbash$ cvs import srcDir vname vrel
This imports all the files in ~/YourAppDir and places them in YourAppDir module under CVS. vname and vrel are vendor name and vendor release ids. They are required, but can be any value, usually related to vendor values (vrel has no relation to the CVS version numbers).
bash$ ls $CVSROOT/YourAppDir
Now, you must get your files out:bash$ cd ~ # recall code is in ~/YourAppDir
bash$ cvs checkoutYourAppDir
This command checks out all the code in CVS moduleYourAppDir
.
Since you are in the parent directory containingYourAppDir
,
the contents ofYourAppDir
are overwritten by what is in CVS.
B:: As ROOT
To make the service available to be used:
Under SuSE 9.0 and RedHat 8.0, edit the file /etc/xinitd.d/cvs to contain:
Under SLES 10 edit /etc/xinetd.d/cvs
======================================
{
server = /usr/bin/cvs
server_args = -f –allow-root=/home/cvsrep pserver
port = 2401 # default
socket_type = stream # default
wait = no # default
user = root # default
passenv = PATH # default
}
======================================
Restart xinetd (need to be root) using:
bash# /etc/init.d/xinetd restart
Usually the configuration is finish here ... check this if yours is not working