~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/shelf_ui.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2010-06-17 17:35:17 UTC
  • mfrom: (5303.2.1 integration)
  • Revision ID: pqm@pqm.ubuntu.com-20100617173517-cldr2otzfopnb5g1
(vila) Show unicode filenames in diff headers using terminal encoding
        (Alexander Belchenko)

Show diffs side-by-side

added added

removed removed

Lines of Context:
241
241
            new_tree = self.work_tree
242
242
        old_path = old_tree.id2path(file_id)
243
243
        new_path = new_tree.id2path(file_id)
244
 
        text_differ = diff.DiffText(old_tree, new_tree, diff_file)
 
244
        text_differ = diff.DiffText(old_tree, new_tree, diff_file,
 
245
            path_encoding=osutils.get_terminal_encoding())
245
246
        patch = text_differ.diff(file_id, old_path, new_path, 'file', 'file')
246
247
        diff_file.seek(0)
247
248
        return patches.parse_patch(diff_file)
493
494
        new_tree = tt.get_preview_tree()
494
495
        if self.write_diff_to is None:
495
496
            self.write_diff_to = ui.ui_factory.make_output_stream()
496
 
        diff.show_diff_trees(merger.this_tree, new_tree, self.write_diff_to)
 
497
        path_encoding = osutils.get_diff_header_encoding()
 
498
        diff.show_diff_trees(merger.this_tree, new_tree, self.write_diff_to,
 
499
            path_encoding=path_encoding)
497
500
        tt.finalize()
498
501
 
499
502
    def show_changes(self, merger):