copyright © 2015 - curt hill tortoise svn a subversion client

29
Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Upload: damian-flowers

Post on 18-Jan-2016

236 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Copyright © 2015 - Curt Hill

Tortoise SVN

A Subversion Client

Page 2: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Copyright © 2015 - Curt Hill

Introduction• There are least two Tortoise

Windows version control clients• This presentation deals with the

Subversion one– There is also a Mercurial one

• Both of these are shell extensions– An add in to Windows Explorer– AKA File Explorer

• Most actions come from a right click and menu choice on a directory

Page 3: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Getting

• The TortoiseSVN is free• Obtain at Source Forge among

others• I downloaded an MSI file• Double click and its installed

Copyright © 2015 - Curt Hill

Page 4: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Usage• Once installed it is a shell extension

– An add-in to Windows explorer

• There will also be a start menu entry to give access to some other features

• Our first task is to create a repository

• This is done by right clicking a directory that will contain the new repository

Copyright © 2015 - Curt Hill

Page 5: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Creating

Copyright © 2015 - Curt Hill

Page 6: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

This Happens Next

Copyright © 2015 - Curt Hill

Page 7: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Resulting Directory

Copyright © 2015 - Curt Hill

Page 8: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Filling the Repository

• What do we want in the repository?

• Two options– Import an existing subversion

repository– Populate it with a new project

Copyright © 2015 - Curt Hill

Page 9: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Import• The import process is to make a

source directory part of the repository• This is the initial check in• Recall that there are certain files that

should not be checked– Anything that can be generated

• Subversion has a set of files that it will not check in but this may not be right– Found in preferences

Copyright © 2015 - Curt Hill

Page 10: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Preferences

Copyright © 2015 - Curt Hill

Page 11: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Importing a Project

• Clean the directory structure– Remove anything that is pointless to

commit

• Right click on the directory to import

• Enter the URL of the repository• Consider the following screens

Copyright © 2015 - Curt Hill

Page 12: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Adding crdp directory

Copyright © 2015 - Curt Hill

Page 13: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Next

Copyright © 2015 - Curt Hill

Page 14: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Results

Copyright © 2015 - Curt Hill

Page 15: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Now What?

• The repository is now tracking things

• However, there is nothing to track until some changes are made

• Changes are handled by the process:– Check out code– Modify/test– Commit (or check in)

Copyright © 2015 - Curt Hill

Page 16: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Process

• Right click on directory you wan things stored

• Choose SVN Checkout• Fill in the dialog box items• As the following screens show, the

directory is d:\temp and repository is one created earlier

Copyright © 2015 - Curt Hill

Page 17: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Check Out

Copyright © 2015 - Curt Hill

Page 18: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Next

Copyright © 2015 - Curt Hill

Page 19: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Finished

Copyright © 2015 - Curt Hill

Page 20: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Dialog Box

• The output directory is called the sandbox– This is where we will work on the code

before check in

• Since fully recursive was checked, the entire directory tree is extracted

• There is some discrepancies in sizes and files between the original, the repository and the new

Copyright © 2015 - Curt Hill

Page 21: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Files

Directory Files Directories

Size

Original 269 4 43.2Repository 36 10 11.4MSandbox 458 151 75.2M

Copyright © 2015 - Curt Hill

• Subversion is still holding onto the new directory

• Keeping track of what will become of the files in it

Page 22: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Development

• Normal development now ensues• Edit files• Compile • Test• Repeat until you are happy• Then put them back in

Copyright © 2015 - Curt Hill

Page 23: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Changes have occurred

Copyright © 2015 - Curt Hill

Page 24: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Starting Commit

Copyright © 2015 - Curt Hill

Page 25: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Next

Copyright © 2015 - Curt Hill

Page 26: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Commit Finished

Copyright © 2015 - Curt Hill

Page 27: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

File Status• Every file in the sandbox has one of

four possible statuses:• Unchanged and current

• Repo and local version match

• Changed and current• An update awaiting a commit

• Unchanged and out of date• Repository version of this has been updated

• Changed and out of date• Both local and repository have been

independently updated

Copyright © 2015 - Curt Hill

Page 28: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Copyright © 2015 - Curt Hill

Page 29: Copyright © 2015 - Curt Hill Tortoise SVN A Subversion Client

Finally

• That is the cycle• Check out • Change• Commit• You do not need to check out again

– Instead several commits may be done

Copyright © 2015 - Curt Hill