diff mercurial/cmdutil.py @ 26533:3e61b325e79a

bundle: use bundle2 if repository uses general delta As bundle1 does not support generaldelta, this would mean recomputing delta at bundle time. This is similar to what we do for strip and shelve and was tracked as issue4865.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Thu, 01 Oct 2015 20:31:43 -0700
parents 1d1d0914cb76
children e99c3846d78a
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Thu Oct 01 20:21:16 2015 -0700
+++ b/mercurial/cmdutil.py	Thu Oct 01 20:31:43 2015 -0700
@@ -3374,6 +3374,8 @@
 
     if version is None:
         version = '01'
+        if 'generaldelta' in repo.requirements:
+            version = '02'
     else:
         try:
             version = _bundleversionspecs[version]