Fix translation script

This commit is contained in:
Julia Radzhabova 2020-11-05 23:37:05 +03:00
parent 43e46ec3b7
commit 9b78c304fb

View file

@ -11,6 +11,9 @@ def strSplit(str):
indLast = str.rfind('"')
result.append(str[ind3+1:indLast])
return result
def sortByAlphabet(inputStr):
return inputStr.lower()
app_names = ['documenteditor', 'presentationeditor', 'spreadsheeteditor']
app_types = ['embed', 'main', 'mobile']
prefix_apps = '../apps/'
@ -40,6 +43,7 @@ for i in range(len(app_names)):
arr = strSplit(lines[k])
if len(arr) > 0:
str_apps.append(arr[0])
str_apps.sort(key=sortByAlphabet)
for l in range(len(langs)):
lang = langs[l].split('.')[0]
f = io.open(locale_path + lang+ '.json', mode='r', encoding='utf-8')