uncommit and bound branches

Robert Collins robertc at robertcollins.net
Thu Mar 30 23:55:43 BST 2006


On Thu, 2006-03-30 at 11:53 -0500, Aaron Bentley wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Erik Bågfors wrote:
> > Say that I have a central branch, and have two developer having done a
> > checkout on that branch (a bound branch checkout).  They are both up
> > to date and now one developer uncommits the last commit.  What happens
> > then?
> > 
> > I assume that the other developer has to run bzr update and the commit
> > will show up as if he did "commit --local" on it?  Is that good?
> 
> It's bad, because it will resurrect the uncommitted revision.
> 
> > Would it be better to say "sorry, can't uncommit with a bound branch/checkout"
> 
> Maybe in the shared-branch case, but it's too useful in the
> branch-per-developer case.  Even in the shared-branch case, there should
> be a better way of handling it.

Thats what I was suggesting uncommit --local for.

There are several states and action combinations:
 A tip of the local branch == tip of master branch, uncommit locally
   useful to allow committing a working-in-progress but continuing to
   work on it in more detail locally. Not -very- useful, but useful.
 B tip of the local branch == tip of master branch, uncommit both.
 C tip of the local branch == tip of master branch, uncommit master
only. (makes the local tip something that a full commit, or a push, will
push into the master)
 D tip of the local branch is on the master branch history, but not the
tip of the master, uncommit locally
   same basic case as A
 E tip of the local branch is on the master branch history, but not the
tip of the master, uncommit both
   this appears to be hard to control
 F tip of the local branch is on the master branch history, but not the
tip of the master, uncommit master only
   this could be useful, if only to back out something someone else did
to a shared branch without pulling it down locally first.
 G tip of the local branch is not on the master branch history, uncommit
locally
   definately useful when using 'commit --local'.
 H tip of the local branch is not on the master branch history, uncommit
both
   seems hard to control again,
 I tip of the local branch is not on the master branch history, uncommit
master only
   looks like case F again.

So - what cases should we support, and how should the user specify which
one they want?

Rob

Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060331/be9634ab/attachment.pgp 


More information about the bazaar mailing list