generate_lang_file.php : try translating message using gettext before asking it

This commit is contained in:
Benjamin Renard 2019-06-05 13:48:21 +02:00
parent 1294d5f392
commit 37e0db032b

View file

@ -165,6 +165,9 @@ function add($msg, $context=null) {
if (array_key_exists($msg, $translations)) {
$translation = $translations[$msg];
}
elseif (_($msg) != $msg) {
$translation = _($msg);
}
elseif ($interactive && $format != 'pot') {
if ($copyoriginalvalue) {
fwrite(STDERR, "\"$msg\"\n\n => Please enter translated string (or leave empty to copy original string) : ");