changeset 3998dc400671 in tryton-tools:default
details: https://hg.tryton.org/tryton-tools?cmd=changeset&node=3998dc400671
description:
Find right language in the file path of tryton
diffstat:
import_weblate.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diffs (14 lines):
diff -r b2813007cfbc -r 3998dc400671 import_weblate.py
--- a/import_weblate.py Sun May 02 10:00:59 2021 +0200
+++ b/import_weblate.py Sun May 02 10:20:28 2021 +0200
@@ -26,6 +26,10 @@
filepath = os.path.abspath(filepath)
basename = os.path.basename(filepath)
language, _ = os.path.splitext(basename)
+ if language == 'tryton':
+ # tryton path is data/locale/<lang>/LC_MESSAGES/tryton.po
+ language = os.path.basename(
+ os.path.dirname(os.path.dirname(filepath)))
if language not in LANGUAGES:
continue
output = os.path.join(