The SCCS command and file system are primarily used to control access to a file and to track who altered a file, why it was altered, and what was altered.
Three kinds of access can be controlled in an SCCS file system:
Directories containing SCCS files should be created with permission code 755 (read, write, and execute permissions for owner; read and execute permissions for group members and others). The SCCS files themselves should be created as read-only files (444). With these permissions, only the owner can use non-SCCS commands to modify SCCS files. If a group can access and modify the SCCS files, the directories should have group write permission.
The admin command with the -a flag can designate a group of users that can make changes to the SCCS file. A group name or number can also be specified with this flag.
The admin command can lock, or prevent, various versions of a file from being accessed by the get command. The -fc header flag sets a ceiling on the highest release number that can be retrieved. The -ff header flag sets a floor on the lowest release number that can be retrieved. And the -fl header flag locks a particular release against being retrieved.
There are three ways to track changes to an SCCS file:
After an SCCS file is updated and a new delta created, the system prompts for comments to be associated with that delta. These comments can be up to 512 characters long and can be modified with the cdc command. The get command with the -l flag prints out the delta table and all the delta comments for any version of a file. In addition to storing the comments associated with a delta, the delta table automatically stores the time and date of the last modification, the real user ID at the time of the modification, the serial numbers of the delta and its predecessor, and any MR numbers associated with the delta.
The admin command with the -fv flag prompts for MR numbers each time a delta is created. A program can be specified with the -fv flag to check the validity of the MR numbers when an attempt is made to create a new delta in the SCCS file. If the MR validity-checking program returns a nonzero exit value, the update will be unsuccessful.
The MR validity-checking program is created by the user. It can be written to track changes made to the SCCS file and index them against any other database or tracking system.
The sccsdiff command compares two SCCS files and prints their differences to standard output. The delta command with the -p flag acts the same as the sccsdiff command when the file is updated. Both of these commands allow you to see what changes have been made between versions.
The prs command reads an SCCS file and writes to standard output any section or information contained within it. This command allows you to find the differences in two versions of a file.
The sccsfile file format.
The admin command, cdc command, delta command, get command, prs command, sccsdiff command.