fix string formats that are ambiguous for translators

This commit is contained in:
Hans-Christoph Steiner 2017-09-15 23:20:29 +02:00
parent 255932453c
commit 6c7b987239
10 changed files with 106 additions and 85 deletions

View file

@ -70,18 +70,19 @@ def main():
parser.error(_("Cannot use --list and --to at the same time"))
if options.to is not None and options.to not in supported:
parser.error(_("Unsupported metadata format, use: --to [%s]") % ' '.join(supported))
parser.error(_("Unsupported metadata format, use: --to [{supported}]")
.format(supported=' '.join(supported)))
for appid, app in apps.items():
path = app.metadatapath
base, ext = common.get_extension(path)
if not options.to and ext not in supported:
logging.info(_("Ignoring %s file at '%s'") % (ext, path))
logging.info(_("Ignoring {ext} file at '{path}'").format(ext=ext, path=path))
continue
elif options.to is not None:
logging.info(_("rewriting '%s' to %s") % (appid, options.to))
logging.info(_("Rewriting '{appid}' to '{path}'").format(appid=appid, path=options.to))
else:
logging.info(_("rewriting '%s'") % (appid))
logging.info(_("Rewriting '{appid}'").format(appid=appid))
to_ext = ext
if options.to is not None: