Mercurial > public > mercurial-scm > hg
comparison mercurial/exchange.py @ 20933:d3775db748a0
localrepo: move the addchangegroup method in changegroup module
This is a gratuitous code move aimed at reducing the localrepo bloatness.
The method had few callers, not enough to be kept in local repo.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Tue, 01 Apr 2014 15:27:53 -0700 |
parents | 91b47139d0cb |
children | dba91f8060eb |
comparison
equal
deleted
inserted
replaced
20932:0ac83e4e4f7c | 20933:d3775db748a0 |
---|---|
506 raise util.Abort(_("partial pull cannot be done because " | 506 raise util.Abort(_("partial pull cannot be done because " |
507 "other repository doesn't support " | 507 "other repository doesn't support " |
508 "changegroupsubset.")) | 508 "changegroupsubset.")) |
509 else: | 509 else: |
510 cg = pullop.remote.changegroupsubset(pullop.fetch, pullop.heads, 'pull') | 510 cg = pullop.remote.changegroupsubset(pullop.fetch, pullop.heads, 'pull') |
511 pullop.cgresult = pullop.repo.addchangegroup(cg, 'pull', | 511 pullop.cgresult = changegroup.addchangegroup(pullop.repo, cg, 'pull', |
512 pullop.remote.url()) | 512 pullop.remote.url()) |
513 | 513 |
514 def _pullphase(pullop): | 514 def _pullphase(pullop): |
515 # Get remote phases data from remote | 515 # Get remote phases data from remote |
516 pullop.todosteps.remove('phases') | 516 pullop.todosteps.remove('phases') |