~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/conflicts.py

  • Committer: Alexander Belchenko
  • Date: 2006-07-31 16:12:57 UTC
  • mto: (1711.2.111 jam-integration)
  • mto: This revision was merged to the branch mainline in revision 1906.
  • Revision ID: bialix@ukr.net-20060731161257-91a231523255332c
new official bzr.ico

Show diffs side-by-side

added added

removed removed

Lines of Context:
88
88
 
89
89
 
90
90
def resolve(tree, paths=None, ignore_misses=False):
91
 
    tree.lock_tree_write()
 
91
    tree.lock_write()
92
92
    try:
93
93
        tree_conflicts = tree.conflicts()
94
94
        if paths is None:
432
432
 
433
433
    typestring = 'unversioned parent'
434
434
 
435
 
    format = 'Conflict because %(path)s is not versioned, but has versioned'\
436
 
             ' children.  %(action)s.'
 
435
    format = 'Conflict adding versioned files to %(path)s.  %(action)s.'
437
436
 
438
437
 
439
438
class MissingParent(HandledConflict):
440
439
    """An attempt to add files to a directory that is not present.
441
 
    Typically, the result of a merge where THIS deleted the directory and
442
 
    the OTHER added a file to it.
443
 
    See also: DeletingParent (same situation, reversed THIS and OTHER)
 
440
    Typically, the result of a merge where one tree deleted the directory and
 
441
    the other added a file to it.
444
442
    """
445
443
 
446
444
    typestring = 'missing parent'
448
446
    format = 'Conflict adding files to %(path)s.  %(action)s.'
449
447
 
450
448
 
451
 
class DeletingParent(HandledConflict):
452
 
    """An attempt to add files to a directory that is not present.
453
 
    Typically, the result of a merge where one OTHER deleted the directory and
454
 
    the THIS added a file to it.
455
 
    """
456
 
 
457
 
    typestring = 'deleting parent'
458
 
 
459
 
    format = "Conflict: can't delete %(path)s because it is not empty.  "\
460
 
             "%(action)s."
461
 
 
462
449
 
463
450
ctype = {}
464
451
 
471
458
 
472
459
 
473
460
register_types(ContentsConflict, TextConflict, PathConflict, DuplicateID,
474
 
               DuplicateEntry, ParentLoop, UnversionedParent, MissingParent,
475
 
               DeletingParent,)
 
461
               DuplicateEntry, ParentLoop, UnversionedParent, MissingParent,)