##// END OF EJS Templates
changegroup: move manifest unpacking into its own method...
Augie Fackler -
r26712:04176eaf default
parent child Browse files
Show More
@@ -287,6 +287,18 b' class cg1unpacker(object):'
287 287 pos = next
288 288 yield closechunk()
289 289
290 def _unpackmanifests(self, repo, revmap, trp, prog, numchanges):
291 # We know that we'll never have more manifests than we had
292 # changesets.
293 self.callback = prog(_('manifests'), numchanges)
294 # no need to check for empty manifest group here:
295 # if the result of the merge of 1 and 2 is the same in 3 and 4,
296 # no new manifest will be created and the manifest group will
297 # be empty during the pull
298 self.manifestheader()
299 repo.manifest.addgroup(self, revmap, trp)
300 repo.ui.progress(_('manifests'), None)
301
290 302 def apply(self, repo, srctype, url, emptyok=False,
291 303 targetphase=phases.draft, expectedtotal=None):
292 304 """Add the changegroup returned by source.read() to this repo.
@@ -357,15 +369,7 b' class cg1unpacker(object):'
357 369
358 370 # pull off the manifest group
359 371 repo.ui.status(_("adding manifests\n"))
360 # manifests <= changesets
361 self.callback = prog(_('manifests'), changesets)
362 # no need to check for empty manifest group here:
363 # if the result of the merge of 1 and 2 is the same in 3 and 4,
364 # no new manifest will be created and the manifest group will
365 # be empty during the pull
366 self.manifestheader()
367 repo.manifest.addgroup(self, revmap, trp)
368 repo.ui.progress(_('manifests'), None)
372 self._unpackmanifests(repo, revmap, trp, prog, changesets)
369 373
370 374 needfiles = {}
371 375 if repo.ui.configbool('server', 'validate', default=False):
General Comments 0
You need to be logged in to leave comments. Login now