Question: Lab 1-16 - Programming Tools Part II: Source code management Material Covered man cvs, man svnand man git Wikipedia page on CVS Wikipedia page on
Lab 1-16 - Programming Tools Part II: Source code management
Material Covered
man cvs, man svnand man git
Wikipedia page on CVS
Wikipedia page on SVN
Wikipedia page on Git
Background
Source code management is used in team software development projects to track version changes and who has made changes in the code. Ideally, this helps one track changes so that later versions of the code do not lose a bug fix from earlier versions of the code (although there are some rather famous security holes caused by people reverting to an old, buggy version of the code). Usually, a revision control system is used to manage the source code. Two popular revision control systems are Concurrent Versions System (CVS) and Subversion (SVN). CVS was derived from an earlier revision control system called RCS that only managed files instead of entire directories ("projects" in CVS terminology). SVN is the successor to CVS. SVN supports most of CVS's features and adds new features.
Both systems provide a way to track changes to a source repository. The basic interaction with the system is to check out files, make changes to the files and then commit those changes back to the repository (so others can access the updated source code). When you check out files, you make your own local copy of those files. Other people may also simultaneously check out the original files and have their own copies of the files. If another person commits their changes to the repository before you do, your local copy of the files will become out-of-date. To deal with this, the revision control systems also give you a way to update your local copies with the latest versions from the repository. To prevent losing your own changes to the file, the revision control system will update your local copy while retaining your changes if possible (it may have issues when your changes overlap with other users' changes).
This allows multiple users to check out and change source code, while keeping consistency across the versions by allowing each user to update with the latest changes. It also allows the administrator to keep track of which users have made changes by logging each commit.
Lab Writeup
Answer the following questions...
1. What is the purpose of source code management?
2. Give the CVS command to check out a project called MyProject.
3. Give the CVS command to commit a file called calc.cpp in MyProject.
4. Give the CVS command to update a file called calc.cpp in MyProject.
5. Give the CVS command to create the repository called MyProject from the current working directory.
6. Give the CVS command to extract a release called Version1 into a directory called V1 under MyProject.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
