Fix #1007468 (Untranslated cli strings)

This commit is contained in:
Kovid Goyal 2012-06-01 21:10:26 +05:30
parent 178da653f3
commit f5f964401d
2 changed files with 280 additions and 250 deletions

File diff suppressed because it is too large Load Diff

View File

@ -89,6 +89,11 @@ class OptionParser(_OptionParser):
formatter=CustomHelpFormatter(), formatter=CustomHelpFormatter(),
conflict_handler=conflict_handler, **kwds) conflict_handler=conflict_handler, **kwds)
self.gui_mode = gui_mode self.gui_mode = gui_mode
for o, msg in {'-h':_('show this help message and exit'), '--version':
_("show program's version number and exit")}.iteritems():
opt = self.get_option(o)
if opt is not None:
opt.help = msg
def error(self, msg): def error(self, msg):
if self.gui_mode: if self.gui_mode: