comparison mercurial/bundle2.py @ 23169:e4dc2b0be056

bundle2caps: advertise the available versions for changegroup packer This will let the bundle2 client and server detect what packer they should be using. This detection part is not done. I expect it to be done with the addition of the second packer (with generaldelta support).
author Pierre-Yves David <pierre-yves.david@fb.com>
date Wed, 24 Sep 2014 21:28:54 -0700
parents e53f6b72a0e4
children 02e8f9b60052
comparison
equal deleted inserted replaced
23168:a92ba36a1a9d 23169:e4dc2b0be056
880 """return the bundle2 capabilities for a given repo 880 """return the bundle2 capabilities for a given repo
881 881
882 Exists to allow extensions (like evolution) to mutate the capabilities. 882 Exists to allow extensions (like evolution) to mutate the capabilities.
883 """ 883 """
884 caps = capabilities.copy() 884 caps = capabilities.copy()
885 caps['b2x:changegroup'] = tuple(sorted(changegroup.packermap.keys()))
885 if obsolete.isenabled(repo, obsolete.exchangeopt): 886 if obsolete.isenabled(repo, obsolete.exchangeopt):
886 supportedformat = tuple('V%i' % v for v in obsolete.formats) 887 supportedformat = tuple('V%i' % v for v in obsolete.formats)
887 caps['b2x:obsmarkers'] = supportedformat 888 caps['b2x:obsmarkers'] = supportedformat
888 return caps 889 return caps
889 890