what to use to replace bzrlib.changeset?

Aaron Bentley aaron.bentley at utoronto.ca
Tue Mar 7 01:04:19 GMT 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jamie Wilkinson wrote:
| This one time, at band camp, Aaron Bentley wrote:
|>I suspect your use case is best handled with merge, which
|>compares two revisions, and applies new changes to a third.

| The problem I had using the merge code last time is that it expected that
| both the merge source and destination branches had a common ancestor

No, that's not required.  You can get some very useful effects by
specifying a base that is not a common ancestor.  For example, if you
want to apply the changes introduced by revno 6, you can do 'bzr merge
- -r 5..6'.

I think what you actually want is to reproduce a series of tree-states,
committing each as a new revision.  If that's right, then
bzrlib.merge.tree_transform should do the trick.

If you need your tree-states to vary from the original ones, then you
simply need to iterate through the revision history, specifying the
previous revision as the base for the current one, each time.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFEDNwS0F+nu1YWqI0RAgGGAJ99o+yRtjwMDSvT74qy/1ZDnNXrpQCfavzM
hIqf1jZYPMAOWkH170Esel0=
=PfBM
-----END PGP SIGNATURE-----




More information about the bazaar mailing list