[RFC] Moving uncommited changes from a tree to another.

Aaron Bentley aaron.bentley at utoronto.ca
Sun Aug 6 21:06:17 BST 2006

Hash: SHA1

Matthieu Moy wrote:
> Hi,
> I started hacking on a branch, and realized that I actually wanted
> those changes in another branch before commiting (I say "branch" since
> I have branches with working tree in the same place).

Yes, that happens to me too, which is what I wrote bzrtools "shove" for.

> In GNU Arch, I did undo in one tree, and redo in the other (and since
> GNU Arch is checkout-based, switch was also an option sometimes).

(bzrtools also provides a "switch" command, though of course it only
works if you're using checkouts.)

> I believe the best way to handle this would be:
> 1) allow revision bundles to refer to uncommited changes. I believe
>    Robert's proposal to consider the working tree as a kind of
>    particular revision goes in this direction too.
> 2) Have "bzr revert" leave a bundle of the state of the tree before
>    revert somewhere.
> 3) Have a way to apply this bundle without creating a new revision. I
>    mean, the changes should appear in the working tree as they used to
>    be.

> Do this sound reasonable? Without this, is there a better option to
> move changes from a tree to another?

I agree this would be good, but I don't think it beats the ease-of-use
of 'bzr shove TARGET-DIR', which of course preserves symlinks and the
execute bit.

Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


More information about the bazaar mailing list