diff mercurial/exchange.py @ 25516:1e37bd83dc66

getbundle: add data about the number of changesets bundled We use an advisory parameters to carry the number of changesets bundled. This will be used for progress output.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Sun, 07 Jun 2015 15:52:57 -0700
parents 60f4e7022ffe
children 521c1a3139c9
line wrap: on
line diff
--- a/mercurial/exchange.py	Wed Jun 10 14:38:09 2015 -0500
+++ b/mercurial/exchange.py	Sun Jun 07 15:52:57 2015 -0700
@@ -1303,6 +1303,7 @@
         part = bundler.newpart('changegroup', data=cg)
         if version is not None:
             part.addparam('version', version)
+        part.addparam('nbchanges', str(len(outgoing.missing)), mandatory=False)
 
 @getbundle2partsgenerator('listkeys')
 def _getbundlelistkeysparts(bundler, repo, source, bundlecaps=None,