mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-12-22 17:51:29 +03:00
use correct language code
This commit is contained in:
parent
80c510acbf
commit
45c521e818
@ -106,10 +106,10 @@ def update_arb_file(source_path, target_path, language_code):
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
source_file_path = 'lib/l10n/app_en.arb'
|
source_file_path = 'lib/l10n/app_en.arb'
|
||||||
target_directory = 'lib/l10n'
|
target_directory = 'lib/l10n'
|
||||||
language_code = os.path.basename(source_file_path).split('_')[1].split('.')[0]
|
|
||||||
|
|
||||||
for file_name in os.listdir(target_directory):
|
for file_name in os.listdir(target_directory):
|
||||||
if file_name.startswith('app_') and file_name.endswith('.arb') and file_name != os.path.basename(source_file_path):
|
if file_name.startswith('app_') and file_name.endswith('.arb') and file_name != os.path.basename(source_file_path):
|
||||||
target_file_path = os.path.join(target_directory, file_name)
|
target_file_path = os.path.join(target_directory, file_name)
|
||||||
|
language_code = file_name.split('_')[1].split('.')[0]
|
||||||
update_arb_file(source_file_path, target_file_path, language_code)
|
update_arb_file(source_file_path, target_file_path, language_code)
|
||||||
print(f'File updated: {file_name}')
|
print(f'File updated: {file_name}')
|
||||||
|
Loading…
Reference in New Issue
Block a user