38
38
from bzrlib.osutils import (pumpfile, quotefn, splitpath, joinpath,
39
39
pathjoin, sha_strings)
40
from bzrlib.errors import (NotVersionedError, InvalidEntryName,
41
BzrError, BzrCheckError, BinaryFile)
40
42
from bzrlib.trace import mutter
41
from bzrlib.errors import (NotVersionedError, InvalidEntryName,
42
BzrError, BzrCheckError)
45
45
class InventoryEntry(object):
572
572
def _diff(self, text_diff, from_label, tree, to_label, to_entry, to_tree,
573
573
output_to, reverse=False):
574
574
"""See InventoryEntry._diff."""
575
from_text = tree.get_file(self.file_id).readlines()
577
to_text = to_tree.get_file(to_entry.file_id).readlines()
581
text_diff(from_label, from_text,
582
to_label, to_text, output_to)
584
text_diff(to_label, to_text,
585
from_label, from_text, output_to)
576
from_text = tree.get_file(self.file_id).readlines()
578
to_text = to_tree.get_file(to_entry.file_id).readlines()
582
text_diff(from_label, from_text,
583
to_label, to_text, output_to)
585
text_diff(to_label, to_text,
586
from_label, from_text, output_to)
589
label_pair = (to_label, from_label)
591
label_pair = (from_label, to_label)
592
print >> output_to, "Binary files %s and %s differ" % label_pair
587
594
def has_text(self):
588
595
"""See InventoryEntry.has_text."""