filemerge: split the logic for finding an external tool to its own function
authorMatt Harbison <matt_harbison@yahoo.com>
Sun, 02 Nov 2014 14:58:50 -0500
changeset 23148 b405dd6c90bf
parent 23147 9174863c58e4
child 23149 dc80a0ad7bf5
filemerge: split the logic for finding an external tool to its own function This will be used by extdiff in an subsequent patch.
mercurial/filemerge.py
--- a/mercurial/filemerge.py	Sun Nov 02 13:18:08 2014 -0800
+++ b/mercurial/filemerge.py	Sun Nov 02 14:58:50 2014 -0500
@@ -37,6 +37,9 @@
 def _findtool(ui, tool):
     if tool in internals:
         return tool
+    return findexternaltool(ui, tool)
+
+def findexternaltool(ui, tool):
     for kn in ("regkey", "regkeyalt"):
         k = _toolstr(ui, tool, kn)
         if not k: