Remote Merge

Nathaniel McCallum npmccallum at gentoo.org
Thu Oct 27 18:31:45 BST 2005


On Thu, 2005-10-27 at 11:43 -0500, John A Meinel wrote:
> Nathaniel McCallum wrote:
> > Maybe I'm missing a command or something here, but this is what I want
> > to do:
> > 
> > bzr branch sftp://my@remote/branch local_branch
> > cd local_branch
> > <make changes to local branch>
> > bzr merge sftp://my@remote/branch
> > 
> > 
> > Is this possible?  This is particularly useful when you have a more
> > central branch that multiple people can commit to (ie. an auto-build
> > branch).
> 
> With your last command, are you trying to merge you changes into the
> remote branch, or merge the remote branch changes into the local one?
> 
> "bzr merge" is used to pull other changes into the local branch.
> 
> The command to push your changes back into a remote branch will be "bzr
> push". Right now, there is no built-in command for this. (I don't think
> it will make 0.6, but it should make 0.7). There are 2 plugins which
> provide for pushing using rsync. I would probably recommend the one in
> Aaron Bentley's "bzrtools" plugin.
> 
> bzr push (like bzr pull) requires that the branches not have diverged.
> So when you push your changes to a published site, that site must not
> have changes that the local branch has not seen.
> 
> The reason is that we do not intend to support merging into a remote
> directory. You can pull the remote changes into the local one, and then
> push again after you have merged the changes locally.

So (?):
  bzr branch sftp://my@remote/branch local_branch
  cd local_branch
  <make changes to local branch>
  bzr merge sftp://my@remote/branch  # Merges remote and local into the local branch
  bzr push sftp://my@remote/branch   # "Commits" to the remote branch

The scenario that we have setup is that we have multiple users each with
their own dev branches and we have some buildbots that build on
"checkin".  Thus, we want to have the ability to have multiple people
commit to the build branches (via ssh keys).  Make sense?

Nathaniel





More information about the bazaar mailing list