Presentation is loading. Please wait.

Presentation is loading. Please wait.

Source Control Dr. Scott Schaefer.

Similar presentations


Presentation on theme: "Source Control Dr. Scott Schaefer."— Presentation transcript:

1 Source Control Dr. Scott Schaefer

2 Version Control Systems
Allow for maintenance and archiving of multiple versions of code / other files Designed for text files… can be used with other files, but some functionality won’t work Saves multiple copies of the same file Tracks changes to each file among multiple users Allows multiple users to edit the same file at the same time

3 Subversion Open-source version control system Builds on CVS
Can handle local or remote repositories Stores and transfers diffs of files… not entire files (efficient)

4 Example Repository User 1 X Z Y User 2

5 Example Repository User 1 add X add Y X Z add Z Y User 2

6 Example Repository User 1 Commit X Z 1 X Z Y Y User 2

7 Example Repository User 1 X Z 1 X Z Y Y User 2 Checkout X Z Y

8 Example Repository User 1 Modify Y X Z 1 X Z Y Y User 2 X Z Y

9 Example Repository User 1 Commit X Z 1 X Z Y Y X Z 2 User 2 Y X Z Y

10 Example Repository User 1 X Z 1 X Z Y Y X Z 2 User 2 Update Y X Z Y

11 Example Repository User 1 Modify X X Z 1 X Z Y Y X Z 2 User 2 Modify X

12 Example Repository User 1 X Z 1 X Z Y Y X Z 2 User 2 Commit Y X Z X Z
3 Y

13 Example merged text! Repository User 1 Update X Z 1 X Z Y Y X Z 2
3 Y

14 Another Example Repository User 1 Delete Z X Z 1 X Y Y User 2 X Z Y

15 Another Example Repository User 1 Commit X Z 1 X Y Y X 2 User 2 Y X Z

16 Another Example Repository User 1 X Z 1 X Y Y X 2 User 2 Update Y X Y

17 Conflicts Happens when you and someone else edit the same line of code
<<<<<<<<< .mine Your change ========= Someone else’s change >>>>>>>>> .r 23 Subversion keeps both your original (foo.mine) and the revision (foo.23)

18 Living with Version Control
ALWAYS update before you commit changes If files change during the update, make sure everything works before you commit If you have a conflict, you MUST resolve the conflict before committing Update often to avoid conflicts Add descriptions to all of your commits

19 Your Project You MUST use version control for all of your projects
I strongly suggest using Google Code as your SVN server You can access it from anywhere


Download ppt "Source Control Dr. Scott Schaefer."

Similar presentations


Ads by Google