[PATCH 1 of 4] ui: allow edit() to work with revision extras

Alexander Drozdov al.drozdov at gmail.com
Thu Feb 6 22:25:58 CST 2014


# HG changeset patch
# User Alexander Drozdov <al.drozdov at gmail.com>
# Date 1391672308 -14400
#      Thu Feb 06 11:38:28 2014 +0400
# Node ID 46b0c64cc27c14e91b96b8c2a2b31aff51ea1002
# Parent  9fe578297b5c3f63512cc003c6fcdca85fa66435
ui: allow edit() to work with revision extras

Make edit() to accept optional 'extra' dictionary.

diff --git a/mercurial/ui.py b/mercurial/ui.py
--- a/mercurial/ui.py
+++ b/mercurial/ui.py
@@ -712,7 +712,7 @@
         if self.debugflag:
             opts['label'] = opts.get('label', '') + ' ui.debug'
             self.write(*msg, **opts)
-    def edit(self, text, user):
+    def edit(self, text, user, extra={}):
         (fd, name) = tempfile.mkstemp(prefix="hg-editor-", suffix=".txt",
                                       text=True)
         try:


More information about the Mercurial-devel mailing list