[MERGE] Cherrypick support for annotate merge

Andrew Bennetts andrew at canonical.com
Thu Dec 20 02:21:37 GMT 2007


Andrew Bennetts has voted tweak.
Status is now: Conditionally approved
Comment:
The code looks straightforward and clean.  Just a couple of comments:

+    def _subtract_plans(old_plan, new_plan):
+        # Can't use patience diff-- C version doesn't work with tuples

The update to the C version to allow tuples just landed. :)

+    def prepare_cherrypick(self):
+        this_tree = self.make_branch_and_tree('this')
+        self.build_tree_contents([('this/file', "a\n")])
+        this_tree.add('file')
+        this_tree.commit('rev1')
+        other_tree = 
this_tree.bzrdir.sprout('other').open_workingtree()
+        self.build_tree_contents([('other/file', "a\nb\n")])
+        other_tree.commit('rev2b', rev_id='rev2b')
+        self.build_tree_contents([('other/file', "c\na\nb\n")])
+        other_tree.commit('rev3b', rev_id='rev3b')
+        this_tree.lock_write()
+        self.addCleanup(this_tree.unlock)
+        return this_tree, other_tree

A docstring on this helper that briefly explains the trees it returns 
would be good.


For details, see: 
http://bundlebuggy.aaronbentley.com/request/%3C475C8399.3040201%40utoronto.ca%3E



More information about the bazaar mailing list