Mercurial > public > mercurial-scm > hg-stable
diff mercurial/localrepo.py @ 1983:ae12a81549a7
Pass correct username as $HGUSER to hgeditor if "commit -u" is used.
And only use the new util.system parameter to set the environment.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Tue, 21 Mar 2006 12:45:27 +0100 |
parents | 736b6c96bbbc |
children | 719cf07b076d |
line wrap: on
line diff
--- a/mercurial/localrepo.py Tue Mar 21 12:15:25 2006 +0100 +++ b/mercurial/localrepo.py Tue Mar 21 12:45:27 2006 +0100 @@ -442,6 +442,7 @@ new = new.keys() new.sort() + user = user or self.ui.username() if not text: edittext = [""] if p2 != nullid: @@ -454,13 +455,12 @@ # run editor in the repository root olddir = os.getcwd() os.chdir(self.root) - edittext = self.ui.edit("\n".join(edittext)) + edittext = self.ui.edit("\n".join(edittext), user) os.chdir(olddir) if not edittext.rstrip(): return None text = edittext - user = user or self.ui.username() n = self.changelog.add(mn, changed + remove, text, tr, p1, p2, user, date) self.hook('pretxncommit', throw=True, node=hex(n), parent1=xp1, parent2=xp2)