~abentley/bazimport/dev

« back to all changes in this revision

Viewing changes to baz_import.py

  • Committer: Aaron Bentley
  • Date: 2008-10-23 17:04:00 UTC
  • Revision ID: aaron@aaronbentley.com-20081023170400-0muqv75jzmenhcy6
Fix import with existing revisions

Show diffs side-by-side

added added

removed removed

Lines of Context:
606
606
            target_branch = wt.branch
607
607
        else:
608
608
            target_branch = create_branch(output_dir)
 
609
    initial_revno = target_branch.revno()
609
610
 
610
611
    for i, revision in enumerate(ancestors):
611
612
        rev_id = revision_id(revision, encoding)
620
621
            yield Progress("revisions", i, len(ancestors))
621
622
 
622
623
        if target_branch.repository.has_revision(rev_id):
623
 
            target_branch.set_last_revision_info(i+1, rev_id)
 
624
            target_branch.set_last_revision_info(i + 1 + initial_revno, rev_id)
624
625
            continue
625
626
        if revdir is None:
626
627
            revdir = os.path.join(tempdir, "rd")