Malcolm Yoke Hean Low

Web page of Malcolm Yoke Hean Low, School of Computer Engineering, NTU

Google





View Malcolm Low's profile on LinkedIn

Quick Guide to CVS

Posted on Monday, January 09, 2006 at 11:55 PM by Malcolm

Here is a quick guide to setting up and using CVS. The commands shown below was tested on Concurrent Versions System (CVS) 1.10 available from Cyclic Software

See also

Setup

  • Set CVSROOT to a directory (e.g. setenv CVSROOT ~/cvsroot )
  • Run "cvs init"

Put Project into CVS

  • To add version control for a project consist of multiple files in a directory, e.g. ~/project
  • cd to ~/project
  • Run "cvs import -m "Project" myproject sample start"
  • The respective arguments are :
  • cvs -m "Log message" repository vendor-tag release-tags
  • You can put anything you like for the tags and log message.
  • You will need to use "repository" to checkout your files later.

Checkout a Project

  • To checkout a project
  • Run "cvs checkout myproject"
  • You can subsitute "myproject" for any other repositories in the CVS.

Update a Project

  • To update a project after modifying several files
  • Run "cvs commit"
  • An editor will be shown to allow you to add comments on the changes
  • To use another editor eg: xemacs, do "setenv EDITOR xemacs"

Add/Remove File

  • To add a file, run "cvs add filename; cvs commit"
  • To remove a file, run "cvs remove filename; cvs commit"

Topics not covered here

  • Version branches
  • Multiple developers
See also this site for a more comprehensive tutorial.




Bookmark and Share

Edited on: Saturday, September 13, 2008 11:52 PM

Posted in General (RSS)