Revision Control
This presentation is the property of its rightful owner.
Sponsored Links
1 / 20

Revision Control Software Engineering SS 2007 PowerPoint PPT Presentation


  • 47 Views
  • Uploaded on
  • Presentation posted in: General

Revision Control Software Engineering SS 2007. Agenda. Revision Control 1. Motivation 2. Overview 3. Tools 4. First Steps 5. Links Objectives - Use revision control system for collaboration. Revision Control. 1. Motivation 2. Overview 3. Tools 4. First Steps 5. Links. Motivation.

Download Presentation

Revision Control Software Engineering SS 2007

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript


Revision control software engineering ss 2007

Revision ControlSoftware Engineering SS 2007


Agenda

Software Engineering, lecture #: Topic 2

Agenda

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links

Objectives

- Use revision control system for collaboration


Revision control

Software Engineering, lecture #: Topic 3

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links


Motivation

Software Engineering, lecture #: Topic 4

Motivation

Usually several developers work on code

Common problems:

Who owns master version

How to collect current version

How to keep code changes consistent

How to roll back bad code changes

Which file versions form Release Candidate 3


Revision control1

Software Engineering, lecture #: Topic 5

Revision Control

Main purpose

Coordinate work from different contributors

Other benefits

Track changes

Access older versions

Name specific set of versions

Split work into different versions


Revision control2

Software Engineering, lecture #: Topic 6

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links


Different flavours

Software Engineering, lecture #: Topic 7

Different flavours

  • File locking

    Only one user can modify a file at any time

    No conflicts, but dead-locks between contributors

    Example: ClearCase

  • Version merging

    All users can modify all files simultaneously

    Conflicts need to be resolved (merging)

    Examples: CVS, subversion


File locations

Software Engineering, lecture #: Topic 8

File locations

Repository

Directory or data base on server

Contains all file versions and information on versions

Never manipulated manually

Working copy

Copy of (part of) repository on local disk

Used to change and add files


Important operations

Software Engineering, lecture #: Topic 9

Important operations

Check-Out

Copy all files from repository to local disk

Commit (Check-In)

Copy changes in working copy to repository

Update

Copy changes in repository to working copy

Merge

Resolve conflicts between working copy and repository

Tag

Name a revision (set of files with versions)


Branch merge

Software Engineering, lecture #: Topic 10

Branch & Merge

  • Branch

    Split off new version

    Used for maintenance releases (bugfix)

    HEAD: main version

  • Merge

    Add changes from one branch to another

    Tag branches after merging!


Revision control3

Software Engineering, lecture #: Topic 11

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links


Cvs concurrent versions system

Software Engineering, lecture #: Topic 12

CVS: Concurrent Versions System

Repository in file system

Requirements

CVS client installed

Write access on server (via shell or NFS)

Front-ends

CrossVC: Windows, Linux, Mac

TortoiseCVS: plug-in for Windows explorer

Eclipse: IDE with built-in CVS


Subversion

Software Engineering, lecture #: Topic 13

Subversion

Repository in data base

“Next version” of CVS

Requirements

subversion client installed

subversion server (standalone or Apache module)

Front-ends

CrossVC: Windows, Linux, Mac

TortoiseSVN: plug-in for Windows explorer

Subclipse: plug-in for Eclipse


Revision control4

Software Engineering, lecture #: Topic 14

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links


Cvs svn first steps

Software Engineering, lecture #: Topic 15

CVS/SVN: First Steps

Create directory on server for repository

CVS: cvs -d /home/me/cvs init

SVN: open https://svn.vis.ethz.ch/, follow instructions

Create local directory with initial files

Move initial files to repository

“Make new module” (TortoiseCVS)

“Import” (CrossVC, TortoiseSVN)

CVS/SVN demo

with Tortoise and/or CrossVC


Good practice

Software Engineering, lecture #: Topic 16

Good Practice

Keep code in repository consistent!

When feature implemented / bug fixed:

Update

Compile

Run automated module tests

Fix bugs

Iterate until no bugs found

Commit


Combining tools

Software Engineering, lecture #: Topic 17

Combining Tools

  • Use build tool to

    compile

    run automated tests

  • Always provide Bug Report ID in commit comment

    register requirements as issues/bugs


Revision control5

Software Engineering, lecture #: Topic 18

Revision Control

1. Motivation

2. Overview

3. Tools

4. First Steps

5. Links


Links

Software Engineering, lecture #: Topic 19

Links

CrossVC

http://www.crossvc.com/

TortoiseCVS, TortoiseSVN

http://www.tortoisecvs.org/

http://tortoisesvn.net/

Eclipse

http://www.eclipse.org/

http://subclipse.tigris.org/


Repositories

Software Engineering, lecture #: Topic 20

Repositories

  • CVS

    directory on nethz account

    accessible via samba (:local:) or secure shell (:ext:)

  • Subversion

    Subversion server provided by VIS

    https://svn.vis.ethz.ch


  • Login