Remote Merge

Erik Bågfors zindar at gmail.com
Fri Oct 28 19:39:01 BST 2005


2005/10/28, John A Meinel <john at arbash-meinel.com>:
> Erik Bågfors wrote:
> >> The plan is to do it like this:
> >> bzr branch sftp://my@remote/branch local_branch
> >> cd local_branch
> >> <hack hack>
> >> bzr commit -m "Made some changes"
> >> Local branch is not up-to-date
> >> $bzr pull
> >> $bzr commit
> >>
> >> That's not decentralized, but it doesn't sound like you really want
> >> decentralized, at least for this branch.
> >
> > So how is the plan to know when a branch should also commit to the
> > remote and when it shouldn't.  The way I see it, if I run "branch",
> > then I want a stand alone branch.  If I want a
> > commit-to-central-branch (I forget what this is called), then maybe we
> > should use another command such as checkout?
>
> I think the idea would be to do a bound checkout.
>
> bzr branch --bound sftp://my@remote/branch local_branch
> <hack hack>
> bzr commit -m "Changes"
> ## Not up-to-date
> bzr pull
> bzr status # Check and see what is going on
> bzr commit -m "Changes"
>
> # Take your laptop offline
> <hack hack>
> bzr commit -m "New changes"
> ## Failed to connect to branch sftp://my@remote/branch
> bzr unbind
> bzr commit -m "New changes"
>
> # Get back to the office
> bzr bind
> ## Trees have diverged
> bzr merge
> bzr commit -m "Merging back to mainline"
> bzr bind # This will push the changes back to mainline
>
> At least that is how I see the bound branches working. I really want to
> be able to unbind I case I go offline, but then be able to rebind when I
> come back online.
>
> To me, that would be a killer feature.
>

To me too. This is exactly what I want.

However, I think that in my case, where we have a bunch of developers
using the same central branch, and that are used to svn and cvs. It
would be very good to not having to explain what bound branches is. 
If "bzr checkout sftp://my@host/branch" could be the same as "bzr
branch --bound sftp://my@host/branch", then they wouldn't notice much
difference between bzr and svn/cvs for simple things.

But that's not that important. the most important thing is to have the
functinality. How it works is not the most important :)

Regards,
Erik




More information about the bazaar mailing list