Supporting cherry-picking

Matthieu Moy Matthieu.Moy at imag.fr
Tue Oct 25 17:46:43 BST 2005


Aaron Bentley <aaron.bentley at utoronto.ca> writes:

> When we do a cherrypick (bzr "merge ../bzr.dev -r -2..-1", where -2 is
> not an ancestor), we do not set any pending-merges.  I believe this to
> be the correct behaviour.

One problem with this is that if you cherrypick all the patches from a
branch, in a different order, then bzr doesn't know you've merged
everything (For this precise scenario, I think Arch's approach is
better).

For example:

I've already merged up to patch-10

revno: 11
  Started feature A
revno: 12
  Very important bug/security fix
revno: 13
  Continued feature A
revno: 14
  Started feature B
revno: 15
  Completed A
revno: 16
  Completed B

I'll probably cherrypick revno 12 immediately, wait for A to be
finished, then cherrypick revno 11, 13 and 15, and when the
contributor commits revision 16, I'll cherrypick 14 and 16.

At the end, I get the same tree as if I had merged from the common
ancestor (10) to revno 16, but 11-16 are still absent from my history.

Perhaps there could be a separate "cherrypick history" that would have
no influence on merging but that would be converted to the usual merge
history when contiguous patches from the common ancestor are merged.

-- 
Matthieu




More information about the bazaar mailing list