An Intro to Concurrent Versions System (CVS) ECE 417/617: Elements of Software Engineering Stan Birchfield Clemson University.

Slides:



Advertisements
Similar presentations
1 IST 410/420 Software Version Control 2 DevelopmentIntegration Test System Test User Acceptance Testing ProductionArchive DEVELOPMENTUSERS - Developers.
Advertisements

Warren Jones, Fluke Co., Eugene Kramer, Remedy Co. Introduction to CVS 1999 Concurrent Versions System Overview of CVS architecture. Repository structure.
Warren Jones, Fluke Co., Eugene Kramer, Remedy Co. Introduction to CVS 1999 Concurrent Versions System Overview of CVS architecture. Repository structure.
Version Control System (Sub)Version Control (SVN).
Version Control System Sui Huang, McMaster University Version Control SystemSui Huang, McMaster University Version Control System -- base on Subversion.
Concepts of Version Control A Technology-Independent View.
Version Control with CVS Peter Dinda Department of Computer Science Northwestern University.
Using subversion COMP 2400 Prof. Chris GauthierDickey.
Concurrent Versioning System Chapter 8 (ALBING’s).
CVS Selim Çıracı Ahmet Kara Metin Tekkalmaz. CVS – Open Source Version Control System Outline What are Version Control Systems? And why do we need them?
CVS II: Parallelizing Software Development Author: Brian Berliner John Tully.
6/27/20151 Doris Lee Concurrent Version System (CVS)
CVS Workshop I Arthur Chan. This workshop CVS overview (10%) Basic CVS commands (40%) Practical Issues in using CVS (50%) My experience in real-life For.
Low level CASE: Source Code Management. Source Code Management  Also known as Configuration Management  Source Code Managers are tools that: –Archive.
Source Code Management Or Configuration Management: How I learned to Stop Worrying and Hate My Co-workers Less.
1 CMPT 275 Software Engineering Revision Control.
Source Control Repositories for Enabling Team Working Svetlin Nakov Telerik Corporation
SubVersioN – the new Central Service at DESY by Marian Gawron.
By Steven Campbell and Erik Boone.  Sharing projects by putting them into a central repository.  Checking out copies of projects from the repository.
Git for Version Control These slides are heavily based on slides created by Ruth Anderson for CSE 390a. Thanks, Ruth! images taken from
Version Control with Subversion. What is Version Control Good For? Maintaining project/file history - so you don’t have to worry about it Managing collaboration.
1 CVS Concurrent Versioning System CRASH COURSE! presented by Axel Polleres with improvements by Holger Lausen and Eyal Oren cf.
Subversion. What is Subversion? A Version Control System A successor to CVS and SourceSafe Essentially gives you a tracked, shared file system.
Introduction to Version Control
Version Control with Subversion Quick Reference of Subversion.
With Mercurial and Progress.   Introduction  What is version control ?  Why use version control ?  Centralised vs. Distributed  Why Mercurial ?
1 Lecture 19 Configuration Management Software Engineering.
Subversion (SVN) Tutorial for CS421 Dan Fleck Spring 2010.
Git A distributed version control system Powerpoint credited to University of PA And modified by Pepper 8-Oct-15.
Version control Using Git Version control, using Git1.
Version Control. How do you share code? Discussion.
Information Systems and Network Engineering Laboratory II DR. KEN COSH WEEK 1.
Chris Onions Getting started with CVS in ATLAS 11 Getting started with CVS in ATLAS Chris Onions (Tutorial based on that of Raúl Ramos Pollán CERN / IT.
Object-Oriented Analysis & Design Subversion. Contents  Configuration management  The repository  Versioning  Tags  Branches  Subversion 2.
Subversion (SVN) A Revision Control System Successor to CVS Carlos Armas Hervey Allen.
Copyright © 2015 – Curt Hill Version Control Systems Why use? What systems? What functions?
Computer Science and Engineering The Ohio State University  Widely used, especially in the opensource community, to track all changes to a project and.
CVS – concurrent versions system Network Management Workshop intERlab at AIT Thailand March 11-15, 2008.
CSE 219 Computer Science III CVS
Configuring Sourceforge’s CVS to work with Forte (3.0 or later) on WindowsNT and Windows 2000 Specific for MAExplorer.sourceforge.net Written by Eric Shen,
Refactoring and Synchronization with the StarTeam Plug-in for Eclipse  Jim Wogulis  Principal Architect, Borland Software Corporation.
CVS – concurrent versions system AROC Guatemala July 19-23, 2010 Guatemala City, Guatemala.
1 CSE306 Operating Systems Projects CVS/SSH tutorial.
CVS: Concurrent Version System Lecturer: Prof. Andrzej (AJ) Bieszczad Phone: “UNIX for Programmers and Users” Third.
1 MSTE Visual SourceSafe For more information, see:
12 CVS Mauro Jaskelioff (originally by Gail Hopkins)
Version Control System
Version Control and SVN ECE 297. Why Do We Need Version Control?
Recitation 2: Abhijit Warkhedi2/25/20161 Today’s Agenda u CVS u GDB.
Subversion (SVN) Tutorial for CS421 Dan Fleck Spring 2010.
Information Systems and Network Engineering Laboratory I DR. KEN COSH WEEK 1.
Warren Jones, Fluke Co., Eugene Kramer, Remedy Co. Introduction to CVS 1999 Revised by David Svoboda 2003 Concurrent Versions System Overview of CVS architecture.
Source Control Repositories for Enabling Team Working Doncho Minkov Telerik Corporation
BIT 285: ( Web) Application Programming Lecture 07 : Tuesday, January 27, 2015 Git.
Git A distributed version control system Powerpoint credited to University of PA And modified by Pepper 28-Jun-16.
Source Control Dr. Scott Schaefer. Version Control Systems Allow for maintenance and archiving of multiple versions of code / other files Designed for.
Concurrent Versions System User guide for CS408
Version Control with Subversion
CVS – concurrent versions system
CVS – concurrent versions system
SVN intro (review).
Version Control.
Source Control Dr. Scott Schaefer.
An Intro to Concurrent Versions System (CVS)
Introduction to Configuration Management With RCS
Concurrent Version System (CVS)
CVS Concurrent Versioning System
Concurrent Versions System
數位芝麻網路公司 蔡志展 2001/8/18 CVS Setup 數位芝麻網路公司 蔡志展 2001/8/18.
Presentation transcript:

An Intro to Concurrent Versions System (CVS) ECE 417/617: Elements of Software Engineering Stan Birchfield Clemson University

What is CVS? CVS –is a version (or revision) control system –maintains entire history of source file (for each change: who, when, and why) –is open-source and free (unlike SourceSafe) What does it do? –stores entire history of each file efficiently –allows multiple people to work simultaneously –enables retrieval of old systems –helps to manage different versions, releases –works well over WAN (server/client) –works for any ASCII file, and limited support for binary What is it not? –a build system –a substitute for management or communication

Why CVS? Problem: how to coordinate source file changes from multiple developers? –Solution #1: Manual merging and coordination –Solution #2: lock-modify-unlock (RCS, SCCS) –Solution #3: concurrent development (CVS)

How CVS manages changes Scenarios: –People work on different files  trivial –People work on different parts of the same file  CVS essentially runs ‘diff’ –People work on the same part of the same file  CVS alerts user, requires manual merging of changes

CVS model Server (Unix/Linux)Local machine (any O/S) Respository: central, official copy, as well as entire history Local copy: used for editing add, remove, commit, tag checkout, update, diff Note: checkout is a one-time operation

CVS directory structure /pub/cvsprojects/ece417 | +--CVSROOT (admin. files) +--3dmm | +-- data | +-- main.cpp,v | +-- database.cpp,v | +-- ui | +-- MainFrame.cpp,v | +-- SettingsDlg.cpp,v | +--klt-ui +--bibtex-manager... C:/user/me/mycode | +--CVS (admin. files) | +--data +-- CVS (admin. files) +-- main.cpp +-- database.cpp +--ui +-- CVS (admin. files) +-- MainFrame.cpp +-- SettingsDlg.cpp Repository on serverCopy on local machine Note: All information stored on a per-file basis

Pserver authentication Each CVS command needs to authenticate you Instead of a password for each command, first login Steps: –cvs login (server checks its passwd file; if no passwd, then falls back to Unix system authentication) –now your password is stored locally in ~/.cvspass –local password is automatically used in the future as long as it’s there –CVS_PASSFILE can be used to change location of.cvspass Note: pserver authentication provides minimal security; do NOT use an important password

CVS commands Syntax: cvs [goptions] command [coptions] [arguments] Example: cvs -d login Common commands: –cvs checkout modules ; create private copy –cvs update ; incorporate others’ changes into private copy –cvs add file ; add private file to repository –cvs remove file ; remove file from repository –cvs commit file ; publish changes to others Customizing: –.cvsrc file contains default options, both global and command- specific

Create / checkout module To put a directory under CVS control, cvs import –m “New file” foo me start –All files in current directory are stored in foo subdirectory of repository –-m “New file” specifies the log comment –foo is directory name in repository –me is vendor tag (can be anything) –start is start tag (can be anything) To checkout a directory, cvs checkout foo –All files in foo subdirectory of repository are copied to current directory

Changing files To add a file to the repository, cvs add file ; takes effect at the next commit To remove a file from the repository, cvs remove file ; takes effect at the next commit To commit changes you’ve made to a file, cvs commit files To tag a file revision, cvs tag –c MyProject-v files (-c warns and aborts if source files are not up-to-date)

Bringing files up to date To bring local files up to date, cvs update –All files in current directory are updated using repository –For each file, prints one-letter code: U (update): your file has been updated with someone’s changes M (merge): same, but you had made changes to the file, too C (conflict): same, but CVS could not merge the changes ? (unknown): file is not under CVS control Note: You cannot commit a file unless it’s up-to-date

Other useful commands To get information about a file, cvs status file To examine a file’s log, cvs log file To see who made what change, cvs annotate file

Conflicts If two people modify the same part of a file, there is a conflict CVS retains both sets of changes in the file, separated by >>> Example: main() { >>>>>> 1.2 }

Setting up server Create a CVS repository if there is not already one Add this to /etc/services: cvs 2401/tcp # remote cvs server Add this to /etc/inetd.conf: cvs stream tcp nowait root /path/to/cvs cvs pserver Restart inetd To encrypt password for CVSHOME/passwd file, –/usr/local/bin/perl -e 'print crypt("MyPassword","St"). "\n";‘ –copy and paste into passwd file as name:epswd To use RSH instead, use :ext instead of :pserver for CVSROOT. Might want to add set CVS_RSH to ssh which makes CVS use SSH and encryption for remote access. Initialize CVS repository, cvs –d /usr/local/cvsrep init ; sets up CVSROOT directory

Versions and revisions Each file has a unique revision number –Even number of dot-separated integers (start with 1.1) –Successive revisions increment the rightmost number Each branch has a unique branch number –Number appended to revision number –Correspond to user versions

Suggested CVS policies Each file has an owner You may –completely modify your own file (but don’t change class interface) –make minor/obvious bug fixes to others’ files, but only if 100% confident (also notify them, just in case) –ask for permission before making bigger changes, or request the change from the developer Alternative: You are never allowed to modify anyone else’s file –Good: no chance of conflict –Bad: extra overhead, not taking advantage of the “C” in CVS (might as well be using lock-modify-unlock)

Other suggestions Make sure system clock reflects real time Frequently update (stay in sync with repository) Frequently commit changes (once compiled, completed, tested, reviewed) Do NOT share code except via repository (e.g., s) Build early, build often (BEBO) Tag early, tag often Save executables associated with tagged builds

Obtaining CVS CvsGui (WinCVS/MacCvs,gCvs): Download and install; this is a GUI front-end and also includes CVS CVS: If you just want the command-line version; documentation is here, too