~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/dirstate.py

  • Committer: Martin Packman
  • Date: 2012-01-05 10:44:12 UTC
  • mfrom: (6424 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6427.
  • Revision ID: martin.packman@canonical.com-20120105104412-z03fi9m43h946fvs
Merge bzr.dev to resolve conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
218
218
 
219
219
"""
220
220
 
 
221
from __future__ import absolute_import
 
222
 
221
223
import bisect
222
224
import errno
223
225
import operator
1559
1561
                    else:
1560
1562
                        source_path = child_basename
1561
1563
                    if new_path_utf8:
1562
 
                        target_path = new_path_utf8 + source_path[len(old_path):]
 
1564
                        target_path = \
 
1565
                            new_path_utf8 + source_path[len(old_path_utf8):]
1563
1566
                    else:
1564
 
                        if old_path == '':
 
1567
                        if old_path_utf8 == '':
1565
1568
                            raise AssertionError("cannot rename directory to"
1566
1569
                                                 " itself")
1567
 
                        target_path = source_path[len(old_path) + 1:]
 
1570
                        target_path = source_path[len(old_path_utf8) + 1:]
1568
1571
                    adds.append((None, target_path, entry[0][2], entry[1][1], False))
1569
1572
                    deletes.append(
1570
1573
                        (source_path, target_path, entry[0][2], None, False))
1571
 
                deletes.append((old_path_utf8, new_path, file_id, None, False))
 
1574
                deletes.append(
 
1575
                    (old_path_utf8, new_path_utf8, file_id, None, False))
 
1576
 
1572
1577
        self._check_delta_ids_absent(new_ids, delta, 1)
1573
1578
        try:
1574
1579
            # Finish expunging deletes/first half of renames.