Mercurial > evolve
diff hgext3rd/topic/discovery.py @ 6566:cb009f13126a
branching: merge with stable
author | Anton Shestakov <av6@dwimlabs.net> |
---|---|
date | Wed, 11 Oct 2023 13:45:08 -0300 |
parents | 2d3771d61068 30d0d3d92c8d |
children | d511eba4cdb0 |
line wrap: on
line diff
--- a/hgext3rd/topic/discovery.py Sat Sep 30 15:41:05 2023 -0300 +++ b/hgext3rd/topic/discovery.py Wed Oct 11 13:45:08 2023 -0300 @@ -355,6 +355,12 @@ # to do the conversion return orig(self, rev, **kwargs) +def wrapaddpartrevbranchcache(orig, repo, bundler, outgoing): + """making sure we send rev-branch-cache that only has bare branches""" + overrides = {(b'_internal', b'tns-disable-fqbn'): True} + with repo.ui.configoverride(overrides, b'topic-namespaces'): + orig(repo, bundler, outgoing) + def wraphgpeer(orig, uiorrepo, opts, *args, **kwargs): """hg.peer() that checks if there are explicit arguments for e.g. pull""" peer = orig(uiorrepo, opts, *args, **kwargs) @@ -395,6 +401,7 @@ extensions.wrapfunction(bundle2, 'handlecheckupdatedheads', handlecheckheads) bundle2.handlecheckupdatedheads.params = frozenset() bundle2.parthandlermapping[b'check:updated-heads'] = bundle2.handlecheckupdatedheads + extensions.wrapfunction(bundle2, 'addpartrevbranchcache', wrapaddpartrevbranchcache) extensions.wrapfunction(exchange, '_pushb2phases', _pushb2phases) exchange.b2partsgenmapping[b'phase'] = exchange._pushb2phases extensions.wrapfunction(hg, 'peer', wraphgpeer)