merge with stable
authorMatt Mackall <mpm@selenic.com>
Fri, 10 Dec 2010 19:20:11 -0600
changeset 13120 8568bbdfbafe
parent 13116 c36dad4f6e54 (current diff)
parent 13119 ecf7d6e0eef0 (diff)
child 13121 bf763946f8b0
merge with stable
mercurial/subrepo.py
--- a/mercurial/hook.py	Fri Dec 10 13:30:37 2010 -0600
+++ b/mercurial/hook.py	Fri Dec 10 19:20:11 2010 -0600
@@ -135,6 +135,9 @@
             elif cmd.startswith('python:'):
                 if cmd.count(':') >= 2:
                     path, cmd = cmd[7:].rsplit(':', 1)
+                    path = util.expandpath(path)
+                    if repo:
+                        path = os.path.join(repo.root, path)
                     mod = extensions.loadpath(path, 'hghook.%s' % hname)
                     hookfn = getattr(mod, cmd)
                 else: