~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/builtins.py

  • Committer: Martin Pool
  • Date: 2009-12-23 05:42:33 UTC
  • mto: This revision was merged to the branch mainline in revision 4923.
  • Revision ID: mbp@sourcefrog.net-20091223054233-7jifhhi9nfo2jt2v
Review tweaks to cmd_update

Show diffs side-by-side

added added

removed removed

Lines of Context:
1426
1426
                # message
1427
1427
                old_tip = branch.update(possible_transports)
1428
1428
            if revision is not None:
1429
 
                rev = revision[0].as_revision_id(branch)
 
1429
                revision_id = revision[0].as_revision_id(branch)
1430
1430
            else:
1431
 
                rev = branch.last_revision()
1432
 
            if rev == _mod_revision.ensure_null(tree.last_revision()):
1433
 
                revno = branch.revision_id_to_revno(rev)
 
1431
                revision_id = branch.last_revision()
 
1432
            if revision_id == _mod_revision.ensure_null(tree.last_revision()):
 
1433
                revno = branch.revision_id_to_revno(revision_id)
1434
1434
                note("Tree is up to date at revision %d of branch %s" %
1435
1435
                    (revno, branch_location))
1436
1436
                return 0
1437
1437
            view_info = _get_view_info_for_change_reporter(tree)
 
1438
            change_reporter = delta._ChangeReporter(
 
1439
                unversioned_filter=tree.is_ignored,
 
1440
                view_info=view_info)
1438
1441
            try:
1439
 
                change_reporter = delta._ChangeReporter(
1440
 
                    unversioned_filter=tree.is_ignored,
1441
 
                    view_info=view_info)
1442
1442
                conflicts = tree.update(
1443
1443
                    change_reporter,
1444
1444
                    possible_transports=possible_transports,
1445
 
                    revision=rev,
 
1445
                    revision=revision_id,
1446
1446
                    old_tip=old_tip)
1447
1447
            except errors.NoSuchRevision, e:
1448
1448
                raise errors.BzrCommandError(