/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/diff.py

  • Committer: Jelmer Vernooij
  • Date: 2017-11-13 12:09:54 UTC
  • mto: This revision was merged to the branch mainline in revision 6819.
  • Revision ID: jelmer@jelmer.uk-20171113120954-qk5p1jcx3zcmf4rr
Fix some more tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
670
670
            return self.CANNOT_DIFF
671
671
        from_label = '%s%s\t%s' % (self.old_label, old_path, old_date)
672
672
        to_label = '%s%s\t%s' % (self.new_label, new_path, new_date)
673
 
        return self.diff_text(from_file_id, to_file_id, from_label, to_label,
674
 
            old_path, new_path)
 
673
        return self.diff_text(old_path, new_path, from_label, to_label,
 
674
            from_file_id, to_file_id)
675
675
 
676
 
    def diff_text(self, from_file_id, to_file_id, from_label, to_label,
677
 
        from_path=None, to_path=None):
 
676
    def diff_text(self, from_path, to_path, from_label, to_label,
 
677
        from_file_id=None, to_file_id=None):
678
678
        """Diff the content of given files in two trees
679
679
 
680
 
        :param from_file_id: The id of the file in the from tree.  If None,
 
680
        :param from_path: The path in the from tree. If None,
681
681
            the file is not present in the from tree.
682
 
        :param to_file_id: The id of the file in the to tree.  This may refer
683
 
            to a different file from from_file_id.  If None,
 
682
        :param to_path: The path in the to tree. This may refer
 
683
            to a different file from from_path.  If None,
684
684
            the file is not present in the to tree.
685
 
        :param from_path: The path in the from tree or None if unknown.
686
 
        :param to_path: The path in the to tree or None if unknown.
 
685
        :param from_file_id: The id of the file in the from tree or None if
 
686
            unknown.
 
687
        :param to_file_id: The id of the file in the to tree or None if
 
688
            unknown.
687
689
        """
688
690
        def _get_text(tree, file_id, path):
689
691
            if file_id is None: