Skip to content
Snippets Groups Projects
Commit cdc3ac89 authored by Pierre-Yves David's avatar Pierre-Yves David
Browse files

wireproto: extract capabilities list in outside the wireproto function

Before that it was over complicated to add capabilities from an extension.

This mimic was is done for capabilities in localrepo.
parent efbf1597
No related branches found
No related tags found
No related merge requests found
......@@ -414,4 +414,7 @@
r.append(encodelist(b) + "\n")
return "".join(r)
wireprotocaps = ['lookup', 'changegroupsubset', 'branchmap', 'pushkey',
'known', 'getbundle', 'unbundlehash', 'batch']
def capabilities(repo, proto):
......@@ -417,6 +420,6 @@
def capabilities(repo, proto):
caps = ('lookup changegroupsubset branchmap pushkey known getbundle '
'unbundlehash batch').split()
# copy to prevent modification of the global list
caps = list(wireprotocaps)
if _allowstream(repo.ui):
if repo.ui.configbool('server', 'preferuncompressed', False):
caps.append('stream-preferred')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment