Show More
@@ -449,3 +449,11 b' def mkstemp(repo, prefix):' | |||
|
449 | 449 | class storeprotonotcapable(Exception): |
|
450 | 450 | def __init__(self, storetypes): |
|
451 | 451 | self.storetypes = storetypes |
|
452 | ||
|
453 | def getcurrentheads(repo): | |
|
454 | branches = repo.branchmap() | |
|
455 | heads = [] | |
|
456 | for branch in branches: | |
|
457 | newheads = repo.branchheads(branch) | |
|
458 | heads = heads + newheads | |
|
459 | return heads |
@@ -660,6 +660,7 b' def override_pull(orig, ui, repo, source' | |||
|
660 | 660 | repo.lfpullsource = source |
|
661 | 661 | if not source: |
|
662 | 662 | source = 'default' |
|
663 | oldheads = lfutil.getcurrentheads(repo) | |
|
663 | 664 | result = orig(ui, repo, source, **opts) |
|
664 | 665 | # If we do not have the new largefiles for any new heads we pulled, we |
|
665 | 666 | # will run into a problem later if we try to merge or rebase with one of |
@@ -667,10 +668,9 b' def override_pull(orig, ui, repo, source' | |||
|
667 | 668 | # cache. |
|
668 | 669 | ui.status(_("caching new largefiles\n")) |
|
669 | 670 | numcached = 0 |
|
670 | branches = repo.branchmap() | |
|
671 | for branch in branches: | |
|
672 | heads = repo.branchheads(branch) | |
|
673 | for head in heads: | |
|
671 | heads = lfutil.getcurrentheads(repo) | |
|
672 | newheads = set(heads).difference(set(oldheads)) | |
|
673 | for head in newheads: | |
|
674 | 674 |
|
|
675 | 675 |
|
|
676 | 676 | ui.status(_("%d largefiles cached\n" % numcached)) |
General Comments 0
You need to be logged in to leave comments.
Login now