Mercurial > evolve
diff hgext3rd/topic/__init__.py @ 5230:8431bb224862
branching: merge with stable
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 07 Apr 2020 19:33:40 +0200 |
parents | 034d6d0efa7d af9f40236037 |
children | 5cfec61b872b |
line wrap: on
line diff
--- a/hgext3rd/topic/__init__.py Sat Mar 21 15:04:18 2020 +0100 +++ b/hgext3rd/topic/__init__.py Tue Apr 07 19:33:40 2020 +0200 @@ -140,6 +140,7 @@ commands, context, error, + exchange, extensions, hg, localrepo, @@ -372,6 +373,8 @@ extensions.wrapfunction(context.workingctx, '__init__', wrapinit) # Wrap changelog.add to drop empty topic extensions.wrapfunction(changelog.changelog, 'add', wrapadd) + # Make exchange._checkpublish handle experimental.topic.publish-bare-branch + extensions.wrapfunction(exchange, '_checkpublish', flow.replacecheckpublish) server.setupserver(ui) @@ -393,6 +396,9 @@ def _restrictcapabilities(self, caps): caps = super(topicrepo, self)._restrictcapabilities(caps) caps.add(b'topics') + if self.ui.configbool(b'experimental', + b'topic.publish-bare-branch'): + caps.add(b'ext-topics-publish=auto') return caps def commit(self, *args, **kwargs):