diff -r f8dc6599da5d -r 9fa429723f26 mercurial/ui.py --- a/mercurial/ui.py Fri Aug 15 04:37:46 2014 +0200 +++ b/mercurial/ui.py Fri Aug 15 23:05:53 2014 +0900 @@ -728,7 +728,7 @@ if self.debugflag: opts['label'] = opts.get('label', '') + ' ui.debug' self.write(*msg, **opts) - def edit(self, text, user, extra={}): + def edit(self, text, user, extra={}, editform=None): (fd, name) = tempfile.mkstemp(prefix="hg-editor-", suffix=".txt", text=True) try: @@ -743,6 +743,8 @@ if label in extra: environ.update({'HGREVISION': extra[label]}) break + if editform: + environ.update({'HGEDITFORM': editform}) editor = self.geteditor()