CVS or DVCS ?
These two notations come across to my head since I’ve gotten to know Mecurial and Git over DVCS or so called Distributed Version Control System.
Apparently, I’ve used CVS - Centralized Version Control System for nearly 1 year now. Mostly I used it on Windows system with the very flexible tool called TortoiseSVN. If I’m coding, I need a version control in place unless I can’t really enjoy coding.
So how we choose between the two systems ?
CVS or DVSC ?
One such project can be collaborated in multiple developers probably for small team 5-10 persons, or merely large team > 20 persons. CVS gives the centralized sense, as when someone would like to push (or commit) their changes into the main trunk, that system needs to check it against the main trunk first to see for conflicts and finally makes the changes. That’s pretty simple kind of task.
Anyway when it goes to merging, the thing could get nasty.
Before we actually merge between the two branches, we need to create or spawn out a new branch first. In CVS, branching out a new one seems a too public. As the main trunk and all branches are seen by everyone. This reduces the encouragement for developers to experiment with the new features. Instead, DVCS encourages this much more.
In DVCS, developers will have their own branch in their local system. This means they are on their own in private environment, they can pull down the source from main, and start doing work offline in their mobile situation when Internet is cut off. Developers can commit the changes to their local repository even those code has bugs or not complete yet, then review back later and finally after everything else is fine and stable they’re going to merge back.
It’s kind of trading-off.
Consider developers working in the tight environment in which they aren’t possibly go out to the Internet or the company limits and applies the network policy then it’s a hard way to pull the code from repository. If this is in CVS, they just can’t do the work especially when they’re in collaborative with others waiting for others to push the changes first. But it’s not the case for DVCS as mentioned earlier, they can pull the latest source before they actually face this situations and be able to work out of box.
In the talk at Google back in 2007 by Linus Tarvalds about perspectives on Git (Git is kind of DVCS), the summary goes in the favor of Git over SVN (SVN is kind of CVS). He usually hates SVN and stated that Git has been used for couple years on developing Linux system and it works like a charm as the performance is far better than SVN. In SVN, you may have to waste your time waiting to download the information about diffs, comments, or full source tree as it needs Internet to get the jobs done but not for Git. In addition to performance, he stated that with Git he and the contributors have merge the source around 22k times a day !
So back to my decision over this. I will try out Git for my personal game projects alone or with colleagues for a couple of weeks to come.
One thing is better is that for Git, there’re notable free source hosting service out there to use i.e. Bitbucket, and GitHub. That’s probably enough to have hands on.
If you want more information, feel free to read this great information.
What’s about you ? What do you use and why is it ?