bundle2: inform transaction that we are in a bundle2 unbundle
authorPierre-Yves David <pierre-yves.david@fb.com>
Thu, 17 Apr 2014 17:16:21 -0400
changeset 21154 e110e2b79135
parent 21153 53ee02b54e53
child 21155 148e98e74e25
bundle2: inform transaction that we are in a bundle2 unbundle That way, hooks called during the unbundle process are aware that a bigger picture is going on.
mercurial/exchange.py
--- a/mercurial/exchange.py	Thu Apr 17 17:46:26 2014 -0400
+++ b/mercurial/exchange.py	Thu Apr 17 17:16:21 2014 -0400
@@ -726,6 +726,7 @@
         # push can proceed
         if util.safehasattr(cg, 'params'):
             tr = repo.transaction('unbundle')
+            tr.hookargs['bundle2-exp'] = '1'
             r = bundle2.processbundle(repo, cg, lambda: tr).reply
             tr.close()
         else: