# HG changeset patch # User Matt Harbison # Date 1531021669 14400 # Node ID 539f9708b980948a5079158cc6d58908d333aae1 # Parent 93ed193bc03e55d928a0bfdc6736370d781a1faf hook: narrow the 'priority' prefix check to align with the documentation A prefix like 'priorityfoo' is meaningless, but `hg help config.hooks` calls out the dot. diff -r 93ed193bc03e -r 539f9708b980 mercurial/hook.py --- a/mercurial/hook.py Sat Jul 07 22:13:56 2018 -0400 +++ b/mercurial/hook.py Sat Jul 07 23:47:49 2018 -0400 @@ -181,7 +181,7 @@ """return all hooks items ready to be sorted""" hooks = {} for name, cmd in ui.configitems('hooks', untrusted=_untrusted): - if not name.startswith('priority'): + if not name.startswith('priority.'): priority = ui.configint('hooks', 'priority.%s' % name, 0) hooks[name] = (-priority, len(hooks), name, cmd) return hooks