comparison mercurial/filemerge.py @ 32294:177742666abd

filemerge: make warning message more i18n friendly Before this patch, " specified for " part of warning messages (e.g. "couldn't find merge tool TOOL specified for PAT") isn't translatable.
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Sat, 13 May 2017 03:28:36 +0900
parents 7d4ce4b567c5
children 7e35d31b41fd
comparison
equal deleted inserted replaced
32293:7d4ce4b567c5 32294:177742666abd
131 return tool in internals and internals[tool].mergetype == nomerge 131 return tool in internals and internals[tool].mergetype == nomerge
132 132
133 def check(tool, pat, symlink, binary, changedelete): 133 def check(tool, pat, symlink, binary, changedelete):
134 tmsg = tool 134 tmsg = tool
135 if pat: 135 if pat:
136 tmsg += " specified for " + pat 136 tmsg = _("%s (for pattern %s)") % (tool, pat)
137 if not _findtool(ui, tool): 137 if not _findtool(ui, tool):
138 if pat: # explicitly requested tool deserves a warning 138 if pat: # explicitly requested tool deserves a warning
139 ui.warn(_("couldn't find merge tool %s\n") % tmsg) 139 ui.warn(_("couldn't find merge tool %s\n") % tmsg)
140 else: # configured but non-existing tools are more silent 140 else: # configured but non-existing tools are more silent
141 ui.note(_("couldn't find merge tool %s\n") % tmsg) 141 ui.note(_("couldn't find merge tool %s\n") % tmsg)