start page | rating of books | rating of authors | reviews | copyrights

Linux in a NutshellLinux in a NutshellSearch this book

Chapter 14. RCS

Contents:

Overview of RCS Commands
Basic RCS Operations
General RCS Specifications
Alphabetical Summary of RCS Commands

The Revision Control System (RCS) offers version control (or revision control), a system that maintains information about a project's evolution so that project members can retrieve prior versions, track changes, and—most importantly— coordinate the efforts of the team. In a typical interaction, a developer checks out the most current code from the repository, makes changes, tests the results, and then commits those changes back to the repository when they are deemed satisfactory.

RCS can keep track of multiple file revisions, thereby reducing the amount of storage space needed. With RCS you can automatically store and retrieve revisions, merge or compare revisions, keep a complete history (or log) of changes, and identify revisions using symbolic keywords.

RCS preceded CVS and performs a similar role. RCS is more limited because it was designed to be used within a single directory and maintains a separate repository in each directory. Although RCS is no longer actively developed, it is still useful for small projects, offering fewer administrative issues than CVS. Projects with large directory structures or with team members on many different computer systems would benefit from using CVS, described in Chapter 15.

RCS uses a locking model to coordinate the efforts of multiple developers by serializing file modifications. Before making changes to a file, a developer must not only obtain a copy of it, but also request and obtain a lock on it from the system. This lock serves to prevent (or really, dissuade) multiple developers from working on the same file at the same time. When the changes are committed, the developer unlocks the file, permitting other developers to gain access to it.

14.1. Overview of RCS Commands

The three most important RCS commands are:

ci
Check in revisions (put a file under RCS control).

co
Check out revisions.

rcs
Set up or change attributes of RCS files.

Two additional commands provide information about RCS files:

ident
Extract keyword values from an RCS file.

rlog
Display a summary (log) about the revisions in an RCS file.

You can compare RCS files with these commands:

rcsdiff
Report differences between revisions.

rcsmerge
Incorporate changes from two RCS files into a third RCS file.

The following command helps with configuration management:

rcsclean
Remove working files that have not been changed.



Library Navigation Links

Copyright © 2003 O'Reilly & Associates. All rights reserved.