Skip to content

Commit

Permalink
remote-bzr: iterate revisions properly
Browse files Browse the repository at this point in the history
This way we don't need to store the list of all the revisions, which
doesn't seem to be very memory efficient with bazaar's design, for
whatever reason.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Felipe Contreras authored and Junio C Hamano committed May 1, 2013
1 parent a397699 commit 38cecbd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions contrib/remote-helpers/git-remote-bzr
Original file line number Diff line number Diff line change
Expand Up @@ -286,9 +286,10 @@ def export_branch(repo, name):
last_revno, _ = branch.last_revision_info()
total = last_revno - tip_revno

revs = [revid, seq for revid, _, seq, _ in revs if not marks.is_marked(revid)]
for revid, _, seq, _ in revs:

for revid, seq in revs:
if marks.is_marked(revid):
continue

rev = repo.get_revision(revid)
revno = seq[0]
Expand Down

0 comments on commit 38cecbd

Please sign in to comment.