Mercurial > public > mercurial-scm > hg-stable
diff mercurial/localrepo.py @ 1838:429bf036f2cb
Call hooks in alphabetical (=defined) order, of course still grouped by type.
Output of test-hook adjusted.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Mon, 06 Mar 2006 17:34:49 +0100 |
parents | bdfb524d728a |
children | 876e4e6ad82b |
line wrap: on
line diff
--- a/mercurial/localrepo.py Sun Mar 05 01:37:28 2006 -0800 +++ b/mercurial/localrepo.py Mon Mar 06 17:34:49 2006 +0100 @@ -85,10 +85,11 @@ return True r = True - for hname, cmd in self.ui.configitems("hooks"): - s = hname.split(".") - if s[0] == name and cmd: - r = runhook(hname, cmd) and r + hooks = [(hname, cmd) for hname, cmd in self.ui.configitems("hooks") + if hname.split(".", 1)[0] == name and cmd] + hooks.sort() + for hname, cmd in hooks: + r = runhook(hname, cmd) and r return r def tags(self):