still use old variable names when running hooks. dropped by accident.
authorVadim Gelfer <vadim.gelfer@gmail.com>
Fri, 17 Mar 2006 09:48:43 -0800
changeset 1967 72f7a335b955
parent 1964 778281d46bb2
child 1968 37dd4928d042
still use old variable names when running hooks. dropped by accident. we set HG_FOO (new name) and FOO (old name). plan is to drop old names after 0.9.
mercurial/localrepo.py
--- a/mercurial/localrepo.py	Wed Mar 15 11:28:00 2006 -0800
+++ b/mercurial/localrepo.py	Fri Mar 17 09:48:43 2006 -0800
@@ -54,7 +54,8 @@
     def hook(self, name, throw=False, **args):
         def runhook(name, cmd):
             self.ui.note(_("running hook %s: %s\n") % (name, cmd))
-            env = dict([('HG_' + k.upper(), v) for k, v in args.iteritems()])
+            env = dict([('HG_' + k.upper(), v) for k, v in args.iteritems()] +
+                       [(k.upper(), v) for k, v in args.iteritems()])
             r = util.system(cmd, environ=env, cwd=self.root)
             if r:
                 desc, r = util.explain_exit(r)