Comparison with Git, Mercurial or Darcs?

Ben Finney ben+bazaar at benfinney.id.au
Thu Nov 5 03:34:25 GMT 2009


Zooko Wilcox-O'Hearn <zooko at zooko.com> writes:

> On Tuesday,2009-11-03, at 23:51 , Ben Finney wrote:
> > This seems to be common to just about everyone I've ever spoken to
> > that likes using Darcs; they don't do much sharing of their
> > repositories with others :-)
>
> I like darcs and I do a lot of sharing repos with others.

Thanks for the counter-example.

> > No, a centralised workflow implies that the repository is in a
> > central location, and is the common commit location for numerous
> > working trees (used by multiple people, or multiple distinct
> > machines by the same person, or both). AIUI most DVCSen can't do
> > this. <URL:http://doc.bazaar-vcs.org/bzr.dev-html/en/tutorials/
> > centralized_workflow.html>.
>
> I don't understand how a DVCS could prevent this, nor how it could
> enforce it.  I do understand how it could facilitate it by making a
> specific remote repo be the default so that you don't have to specify
> it explicitly when you do things, and darcs has the ability to do
> that.  Could you explain more what you mean by this?

I'm not up to speed on the latest in Bazaar, but AIUI the implementation
is:

* The user specifically designates that branch ‘foo/’ is bound to remote
  branch ‘bar/’.

* Any commit into branch ‘foo/’ will always put the revision data into
  branch ‘bar/’ first; if that fails, the *local* commit doesn't happen
  either.

* Other branches can also be bound (by the same person, or other
  people), independently of ‘foo/’, to the same ‘bar/’ branch, which
  implies that they too can commit revisions to ‘bar/’ that aren't in
  ‘foo/’.

* Therefore, committing to branch ‘foo/’ will always fail if it's not
  yet up-to-date with the revision data from branch ‘bar/’, requiring
  ‘foo/’ to be brought up-to-date first (and merge or shelve any local
  changes). Hence, the central branch's version of history has priority
  over any local copy of that branch.

This is similar to non-distributed VCS, and is anathema to distributed
VCS operation, of course, which is why it's called a “centralised VCS”
workflow and is *not* the default operation of Bazaar. But when it's
needed (and I've given examples earlier of when that might be), Bazaar
does it easily.

-- 
 \       “[Freedom of speech] isn't something somebody else gives you. |
  `\      That's something you give to yourself.” —_Hocus Pocus_, Kurt |
_o__)                                                         Vonnegut |
Ben Finney




More information about the bazaar mailing list