~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2008-05-24 11:41:24 UTC
  • mfrom: (3449.1.2 unbreak-push-overwrite)
  • Revision ID: pqm@pqm.ubuntu.com-20080524114124-ubdyd5iqf7zxl2pn
Fix "bzr push --overwrite -r NNN". (Andrew Bennetts)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1670
1670
        result.source_branch = self
1671
1671
        result.target_branch = target
1672
1672
        result.old_revno, result.old_revid = target.last_revision_info()
1673
 
        try:
1674
 
            target.update_revisions(self, stop_revision)
1675
 
        except errors.DivergedBranches:
1676
 
            if not overwrite:
1677
 
                raise
1678
 
        if overwrite:
1679
 
            target.set_revision_history(self.revision_history())
 
1673
        target.update_revisions(self, stop_revision, overwrite)
1680
1674
        result.tag_conflicts = self.tags.merge_to(target.tags, overwrite)
1681
1675
        result.new_revno, result.new_revid = target.last_revision_info()
1682
1676
        return result