Moments of Synchronization - Schumacher & Calvetnchronization - Schumacher & Calvet
AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher
-
Upload
atlassian -
Category
Technology
-
view
1.382 -
download
0
description
Transcript of AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher
![Page 1: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/1.jpg)
2010
![Page 2: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/2.jpg)
The Subversion Dilemma !
Check in buggy code and drive everyone else crazy
Avoid checking it in until it’s fully debugged
or
![Page 3: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/3.jpg)
The Subversion Dilemma !
Weeks without Version Control
![Page 4: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/4.jpg)
Jens Schumacher – Atlassian What is DVCS and why it will change the way we work!
2010
![Page 5: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/5.jpg)
Overview!
1. Mercurial vs. Subversion
2. Basic concepts
3. Use cases
![Page 6: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/6.jpg)
![Page 7: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/7.jpg)
Subversion vs Mercurial!
![Page 8: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/8.jpg)
Subversion vs Mercurial!
Merging
![Page 9: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/9.jpg)
Subversion vs Mercurial!
Branching
![Page 10: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/10.jpg)
Subversion vs Mercurial!
Repository Access
![Page 11: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/11.jpg)
Subversion vs Mercurial!
Performance
![Page 12: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/12.jpg)
Subversion vs Mercurial!
Sharing
![Page 13: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/13.jpg)
Subversion vs Mercurial!
Tool Support
![Page 14: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/14.jpg)
Subversion vs Mercurial!
Authentication
![Page 15: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/15.jpg)
Subversion vs Mercurial!
Check Out
![Page 16: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/16.jpg)
Subversion vs Mercurial!
![Page 17: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/17.jpg)
Overview!
1. Mercurial vs. Subversion
2. Basic concepts
3. Use cases
![Page 18: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/18.jpg)
Repository Architecture!
![Page 19: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/19.jpg)
Subversion!
![Page 20: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/20.jpg)
Mercurial!
![Page 21: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/21.jpg)
Subversion!
Revisions
Subversion is always linear
![Page 22: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/22.jpg)
Mercurial!
Changesets
head
Each Changeset can have multiple children
![Page 23: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/23.jpg)
Mercurial!
head
head
![Page 24: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/24.jpg)
Mercurial!
Pull
Merge
![Page 25: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/25.jpg)
Mercurial!
"hg commit" adds a new node
"hg push" and "hg pull" transfer nodes in the graph between two repositories
"hg merge" merge changes in a repository
![Page 26: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/26.jpg)
Branching in Mercurial!
• Forks"• Named Branches"• Bookmarks"• Anonymous Branches"
![Page 27: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/27.jpg)
Forks!
![Page 28: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/28.jpg)
Forks!
• Complete Isolation"• Very easy to discard"
• Forking is slower"
Disadvantages"Advantages"
1 2
![Page 29: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/29.jpg)
Forks!
When to use Forks"
• When you donʼt have commit access"• To experiment"• For a build repository"
![Page 30: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/30.jpg)
Named Branches!
![Page 31: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/31.jpg)
Named Branches!
• Branch Metadata"• Faster than Forking"
• Branch Metadata"• Closing a Branch
(fixed in 1.2)"
Disadvantages"Advantages"
![Page 32: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/32.jpg)
Named Branches!
When to use Named Branches"
• Working in a team on a feature"
![Page 33: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/33.jpg)
Bookmarks!
![Page 34: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/34.jpg)
Bookmarks!
• Lightweight"• Can be deleted"• Similar to git"
• Local (fixed in 1.6) "• Possible loss of context "
Disadvantages"Advantages"
![Page 35: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/35.jpg)
Bookmarks!
When to use Bookmarks"
• Working in a team on a feature"• If you like to way git does branching"• If you use Mercurial 1.6"
![Page 36: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/36.jpg)
Anonymous Branches!
![Page 37: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/37.jpg)
Anonymous Branches!
• Fast "• No name required"• No closing required"
• No description"• Changeset # required
(lookup with hg log)"
Disadvantages"Advantages"
![Page 38: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/38.jpg)
Anonymous Branches!
When to use Anonymous Branches"
• For quick & small fixes"
![Page 39: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/39.jpg)
Overview!
1. Mercurial vs. Subversion
2. Basic concepts
3. Use cases
![Page 40: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/40.jpg)
BitBucket!
Mercurial code hosting"
• Free for 5 users"• Unlimited public collaborators"• Unlimited disk space"
![Page 41: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/41.jpg)
Getting Started!
![Page 42: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/42.jpg)
The Basics!
hg init create a new repositoryhg commit save your changes in the current repositoryhg log see all changes in your repositoryhg pull pull all changes from another repository into yourshg push push your changes into another repositoryhg merge join different lines of history
hg update update the repository's working directoryhg help <command>
![Page 43: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/43.jpg)
Separate Features!
Use Case Work on several features in parallel
![Page 44: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/44.jpg)
Separate Features!
$ hg clone project feature$ cd feature$ (do some changes and commits)
Clone
![Page 45: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/45.jpg)
Separate Features!
$ cd ../project$ hg incoming ../feature
Incoming
Use hg incoming --patch to view the diffs
![Page 46: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/46.jpg)
Separate Features!
$ hg pull ../feature
Pull
The history of feature one is now in your project. However, changes are not yet visible and only stored in the .hg directory
![Page 47: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/47.jpg)
Separate Features!
$ hg merge
Merge
$ hg commit(enter commit message)
Commit
![Page 48: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/48.jpg)
Separate Features!
Changesets
![Page 49: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/49.jpg)
Collaborative Feature Development!
Use Case Using Mercurial to help coordinate the coding
![Page 50: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/50.jpg)
Collaborative Feature Development!
$ hg branch feature(do some changes)$ hg commit(write commit message)
Create a branch
$ hg update feature(do some changes)$ hg commit(write commit message)
![Page 51: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/51.jpg)
Collaborative Feature Development!
$ hg update default$ hg merge feature$ hg commit(write commit message)
Merge the named branch
Named branches stay in history as permanent records after you finished your work.
![Page 52: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/52.jpg)
Collaborative Feature Development!
Changesets
![Page 53: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/53.jpg)
Tagging Revisions!
Use Case Release a plugin
![Page 54: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/54.jpg)
Tagging Revisions!
$ hg tag -r 8 v0.1
Add a tag
$ hg tags
See all tags
$ hg update v0.1
Update to a tagged revision
![Page 55: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/55.jpg)
Tagging Revisions!
Tags"
![Page 56: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/56.jpg)
Overview!
1. Mercurial vs. Subversion
2. Basic concepts
3. Use cases
![Page 57: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/57.jpg)
Try BitBucket!
bitbucket.org"
![Page 58: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/58.jpg)
Links!
• http://mercurial.selenic.com"• http://stevelosh.com/blog/2009/08/a-guide-to-
branching-in-mercurial"• http://hgbook.red-bean.com/"
![Page 59: AtlasCamp 2010: What is DVCS and why it will change the way we work - Jens Schumacher](https://reader034.fdocuments.in/reader034/viewer/2022051818/54c208934a7959e6068b45ff/html5/thumbnails/59.jpg)
Thank you!!