version control with subversion
DESCRIPTION
Largely based on Vishnu Gopal's presentation http://www.slideshare.net/vishnu/basic-source-control-with-subversionUsed for a quick SVN introduction in a Software Engineering course at Massey University.TRANSCRIPT
![Page 1: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/1.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Software Version Control usingSubversion
Guy K. Kloss
Computer ScienceMassey University, Albany
Softare Engineering 158.329Auckland, 11 May 2009
Guy K. Kloss | Software Version Control using Subversion 1/22
![Page 2: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/2.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 2/22
![Page 3: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/3.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 3/22
![Page 4: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/4.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
What?
Subversion maintains snapshots of the code repository.Allows many people to concurrently work on a codebase.Subversion is source control with a central repository.Usually integrates with a frontend: Trac
Guy K. Kloss | Software Version Control using Subversion 4/22
![Page 5: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/5.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Why?
Continuous incremental backup.Ability to recall older code.Distributed development.Various versions of a single project.Tracking bugs, timeline, goals and releases.
Guy K. Kloss | Software Version Control using Subversion 5/22
![Page 6: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/6.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Central Repository
Guy K. Kloss | Software Version Control using Subversion 6/22
![Page 7: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/7.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
How?
Developers checkout code from the repositoryto a local working-copy.After making edits, they commit changes.At any point, they can revertto an older version of the codebase.They update their local working copy frequentlyto keep up with changes.
Guy K. Kloss | Software Version Control using Subversion 7/22
![Page 8: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/8.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Work with Subversion
Guy K. Kloss | Software Version Control using Subversion 8/22
![Page 9: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/9.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
How does Subversion work?
A system to track changes in files.The code is initially imported into the repository.Then a special “subversion-aware” directoryis checked-out.Developers commit and update.Subversion tracks the changesets and the commit-log.
Guy K. Kloss | Software Version Control using Subversion 9/22
![Page 10: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/10.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 10/22
![Page 11: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/11.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Common Subversion Commands
checkout: Obtain a new working copy.import: Import code into repository initially.commit: Update repository with changes.update: Update working-copy with changes.Other commands: revert, move, copy, merge.
Guy K. Kloss | Software Version Control using Subversion 11/22
![Page 12: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/12.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 12/22
![Page 13: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/13.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
To be shown . . .For examples see slides 49–77 in the presentation“SVN – SubVersioN” here:http://www.slideshare.net/slidesharechaos/svn-subversion
Guy K. Kloss | Software Version Control using Subversion 13/22
![Page 14: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/14.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 14/22
![Page 15: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/15.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
GUI Tools
TortoiseSVN inWindowsRight-click a directory:get a context-menu witheverything in there.Useful Integration withdiff and patch.Reasonably fast.
Guy K. Kloss | Software Version Control using Subversion 15/22
![Page 16: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/16.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 16/22
![Page 17: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/17.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Project Layout
trunk/→ All constant development happens here.branches/→ Special purpose development here.tags/→ Releases are “tagged” for archiving.
Guy K. Kloss | Software Version Control using Subversion 17/22
![Page 18: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/18.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Outline
1 What, Why and How?
2 Subversion Commands
3 Demo: Command-line Tools
4 GUI Tools
5 Project Layout
6 Demo: Trac
Guy K. Kloss | Software Version Control using Subversion 18/22
![Page 19: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/19.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Major features of Trac
Web frontend to a Subversion repository.Shows the changesets and timeline.Has a bug tracker which integrateswith the Subversion commit-log.Simple project management.
Guy K. Kloss | Software Version Control using Subversion 19/22
![Page 20: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/20.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Some good Subversion practices
Follow the branches, tags, trunk structure.All code should be in the repository!Update code at the start of every day.Only commit coherent changes.The central repository should always be consistent.No dependent stuff!Branch as less as possible.
Guy K. Kloss | Software Version Control using Subversion 20/22
![Page 21: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/21.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
Questions?
Guy K. Kloss | Software Version Control using Subversion 21/22
![Page 22: Version Control with Subversion](https://reader034.vdocument.in/reader034/viewer/2022052618/55493770b4c905054d8b4819/html5/thumbnails/22.jpg)
What, Why and How? Subversion Commands Demo: Command-line Tools GUI Tools Project Layout Demo: Trac
References
Thanks to Vishnu Gopal’s presentation“Basic SCM with Subversion & Trac”Subversion Quick Reference Cardhttp://www.digilife.be/quickreferences/quickrefs.htm
Subversion Cheat Sheethttp://ariejan.net/svncheatsheet/
TortoiseSVN client for Windowshttp://tortoisesvn.tigris.org/
Guy K. Kloss | Software Version Control using Subversion 22/22