Distributed Version Control Systems

Distributed Version Control Systems

Prehistory History Linux Bazaar Conclusion Distributed Version Control Systems Matthieu Moy Computer Science and Automation Indian Institute of Science Bangalore October 2006 Matthieu Moy (CSA/IISc) DVC October 2006 < 1 / 43 > Prehistory History Linux Bazaar Conclusion Outline 1 Motivations, Prehistory 2 History and Categories of Version Control Systems 3 Version Control for the Linux Kernel 4 Bazaar (bzr): One Decentralized Revision Control System 5 Conclusion Matthieu Moy (CSA/IISc) DVC October 2006 < 2 / 43 > Prehistory History Linux Bazaar Conclusion Outline 1 Motivations, Prehistory 2 History and Categories of Version Control Systems 3 Version Control for the Linux Kernel 4 Bazaar (bzr): One Decentralized Revision Control System 5 Conclusion Matthieu Moy (CSA/IISc) DVC October 2006 < 3 / 43 > I Replicate: $ cp -r ~/project/ ~/backup/ I Keep history: $ cp -r ~/project/ ~/backup/project-2006-10-4 I Keep a description of history: $ echo "Description of current state" > \ ~/backup/project-2006-10-4/README.txt Historical solutions: Prehistory History Linux Bazaar Conclusion Backups: The Old Good Time Basic problems: I “Oh, my disk crashed.” / “Someone has stolen my laptop!” I “@#%!!, I’ve just deleted this important file!” I “Oops, I introduced a bug a long time ago in my code, how can I see how it was before?” Matthieu Moy (CSA/IISc) DVC October 2006 < 4 / 43 > I Replicate: $ cp -r ~/project/ ~/backup/ I Keep history: $ cp -r ~/project/ ~/backup/project-2006-10-4 I Keep a description of history: $ echo "Description of current state" > \ ~/backup/project-2006-10-4/README.txt Prehistory History Linux Bazaar Conclusion Backups: The Old Good Time Basic problems: I “Oh, my disk crashed.” / “Someone has stolen my laptop!” I “@#%!!, I’ve just deleted this important file!” I “Oops, I introduced a bug a long time ago in my code, how can I see how it was before?” Historical solutions: Matthieu Moy (CSA/IISc) DVC October 2006 < 4 / 43 > I Keep history: $ cp -r ~/project/ ~/backup/project-2006-10-4 I Keep a description of history: $ echo "Description of current state" > \ ~/backup/project-2006-10-4/README.txt Prehistory History Linux Bazaar Conclusion Backups: The Old Good Time Basic problems: I “Oh, my disk crashed.” / “Someone has stolen my laptop!” I “@#%!!, I’ve just deleted this important file!” I “Oops, I introduced a bug a long time ago in my code, how can I see how it was before?” Historical solutions: I Replicate: $ cp -r ~/project/ ~/backup/ Matthieu Moy (CSA/IISc) DVC October 2006 < 4 / 43 > I Keep a description of history: $ echo "Description of current state" > \ ~/backup/project-2006-10-4/README.txt Prehistory History Linux Bazaar Conclusion Backups: The Old Good Time Basic problems: I “Oh, my disk crashed.” / “Someone has stolen my laptop!” I “@#%!!, I’ve just deleted this important file!” I “Oops, I introduced a bug a long time ago in my code, how can I see how it was before?” Historical solutions: I Replicate: $ cp -r ~/project/ ~/backup/ I Keep history: $ cp -r ~/project/ ~/backup/project-2006-10-4 Matthieu Moy (CSA/IISc) DVC October 2006 < 4 / 43 > Prehistory History Linux Bazaar Conclusion Backups: The Old Good Time Basic problems: I “Oh, my disk crashed.” / “Someone has stolen my laptop!” I “@#%!!, I’ve just deleted this important file!” I “Oops, I introduced a bug a long time ago in my code, how can I see how it was before?” Historical solutions: I Replicate: $ cp -r ~/project/ ~/backup/ I Keep history: $ cp -r ~/project/ ~/backup/project-2006-10-4 I Keep a description of history: $ echo "Description of current state" > \ ~/backup/project-2006-10-4/README.txt Matthieu Moy (CSA/IISc) DVC October 2006 < 4 / 43 > Prehistory History Linux Bazaar Conclusion Backups: Improved Solutions Replicate over multiple machines Incremental backups: Store only the changes compared to previous revision I With file granularity I With finer-grained (diff) Many tools available: I Standalone tools: rsync, rdiff-backup,... I Versionned filesystems: VMS, Windows 2003+, cvsfs, . Matthieu Moy (CSA/IISc) DVC October 2006 < 5 / 43 > I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. I People lock the file when working on it. ⇒ Doesn’t scale up! I People work trying to avoid conflicts, and merge later. Historical solutions: Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. I People lock the file when working on it. ⇒ Doesn’t scale up! I People work trying to avoid conflicts, and merge later. Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Historical solutions: Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. I People lock the file when working on it. ⇒ Doesn’t scale up! I People work trying to avoid conflicts, and merge later. Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Historical solutions: I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > I People lock the file when working on it. ⇒ Doesn’t scale up! I People work trying to avoid conflicts, and merge later. Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Historical solutions: I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > I People work trying to avoid conflicts, and merge later. Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Historical solutions: I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. I People lock the file when working on it. ⇒ Doesn’t scale up! Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > Prehistory History Linux Bazaar Conclusion Collaborative Development: The Old Good Time Basic problems: Several persons working on the same set of files 1 “Hey, you’ve modified the same file as me, how do we merge?”, 2 “Your modifications are broken, your code doesn’t even compile. Fix your changes before sending it to me!”, 3 “Your bug fix here seems interesting, but I don’t want your other changes”. Historical solutions: I Never two person work at the same time. When one person stops working, (s)he sends his/her work to the others. ⇒ Doesn’t scale up! Unsafe. I People work on the same directory (same machine, NFS, . ) ⇒ Painful because of (2) above. I People lock the file when working on it. ⇒ Doesn’t scale up! I People work trying to avoid conflicts, and merge later. Matthieu Moy (CSA/IISc) DVC October 2006 < 6 / 43 > Common ancestor #include <stdio.h> int main () { printf("Hello"); return 0; } Tools like diff3 can solve this Merging relies on history! Collaborative development linked to backups Prehistory History Linux Bazaar Conclusion Merging: Problem and Solution My version Your version #include <stdio.h> #include <stdio.h> int main () { int main () { printf("Hello"); printf("Hello!\n"); return EXIT_SUCCESS; return 0; } } Matthieu Moy (CSA/IISc) DVC October 2006 < 7 / 43 > Tools like diff3 can solve this Merging relies on history! Collaborative development linked to

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    89 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us