This is a read-only archive. Find the latest Linux articles, documentation, and answers at the new Linux.com!

Linux.com

Re: Darcs

Posted by: TravisSnoozy on March 11, 2008 02:49 PM

In a nutshell, having gobs of branches may be unavoidable, but you should only ever have the exact number of branches that you need, not more. Each branch needs to be managed — monitored for what needs to be merged into and out of it — and that's a lot of overhead. Merges themselves tend to be awkward, and induce an overhead in figuring out how to perform them correctly (specifically, in the case of both logical and actual conflicts).



In other words, the more you branch, the more you isolate, and isolation is a double-edged sword. It means that your changes don't mess up other parts of the tree, but it also means that you don't realize fixes from other parts of the tree nearly as quickly. It's easy to get into a "right-hand doesn't know what the left-hand is doing" type scenario when there's too much isolation.



On the other hand, I can appreciate that every svn up on a working copy with modifications is roughly equivalent to a mini-merge in and of itself. Darcs (and, I assume, other distributed RCSs) just make that explicit. However, there seems to be an extra management step insofar as needing to make sure that the changes that get recorded locally actually make it back to the main server, and don't languish in these personal branches (the "real" checkin). Furthermore, I would assume that it may be difficult to get "clean" patches if developers don't learn good branch skills in the first place — that is, you could wind up with six interleaved patches in your local repo, which work on two features, but leave the repo in an inconsistent state unless all six are applied (e.g., the earlier patches introduce problems that the later patches fix, and the later patches also finish up the functionality). I percieve this to be less of an issue with managed feature branches, because the delta between start of the branch and end of the branch will always be the "perfect" diff, with the majority of the kinks and bugs worked out — the issue of multiple features being introduced isn't there if you manage it properly.



Hopefully this makes sense. Feel free to poke at any holes you see in my concerns. ;)

#

Return to Better source control for your coding projects