# HG changeset patch # User Pierre-Yves David # Date 2017-06-30 01:27:07 # Node ID 478cb17cc610316e223f878641f1f609665e9b94 # Parent 8b109c61bc113fd0616365d7edf481623766f4bc configitems: register the 'acl.sources' config The existing default value is now formally declared. It seems like the whole config should be a list, but this is an adventure for the next changesets. diff --git a/hgext/acl.py b/hgext/acl.py --- a/hgext/acl.py +++ b/hgext/acl.py @@ -218,6 +218,9 @@ configitem = registrar.configitem(config configitem('acl', 'config', default=None, ) +configitem('acl', 'sources', + default='serve', +) def _getusers(ui, group): @@ -289,7 +292,7 @@ def hook(ui, repo, hooktype, node=None, raise error.Abort(_('config error - hook type "%s" cannot stop ' 'incoming changesets nor commits') % hooktype) if (hooktype == 'pretxnchangegroup' and - source not in ui.config('acl', 'sources', 'serve').split()): + source not in ui.config('acl', 'sources').split()): ui.debug('acl: changes have source "%s" - skipping\n' % source) return