~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/merge.py

Integrated fs conflicts with merge conflicts.

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
import bzrlib.osutils
40
40
from bzrlib.osutils import rename, pathjoin
41
41
from bzrlib.revision import common_ancestor, is_ancestor, NULL_REVISION
42
 
from bzrlib.transform import (TreeTransform, resolve_conflicts, 
 
42
from bzrlib.transform import (TreeTransform, resolve_conflicts, cook_conflicts,
43
43
                              conflicts_strings, FinalPaths, create_by_entry,
44
44
                              unique_add)
45
45
from bzrlib.trace import mutter, warning, note
335
335
                file_status = self.merge_contents(file_id)
336
336
                self.merge_executable(file_id, file_status)
337
337
                
338
 
            resolve_conflicts(self.tt)
339
 
            self.cook_conflicts()
 
338
            fs_conflicts = resolve_conflicts(self.tt)
 
339
            self.cook_conflicts(fs_conflicts)
340
340
            for line in conflicts_strings(self.cooked_conflicts):
341
341
                warning(line)
342
342
            self.tt.apply()
641
641
                trans_id = self.tt.get_trans_id(file_id)
642
642
                self.tt.set_executability(executability, trans_id)
643
643
 
644
 
    def cook_conflicts(self):
 
644
    def cook_conflicts(self, fs_conflicts):
645
645
        """Convert all conflicts into a form that doesn't depend on trans_id"""
646
646
        name_conflicts = {}
 
647
        self.cooked_conflicts.extend(cook_conflicts(fs_conflicts, self.tt))
647
648
        fp = FinalPaths(self.tt)
648
649
        for conflict in self._raw_conflicts:
649
650
            conflict_type = conflict[0]