mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-06-04 11:14:21 +08:00
Set fuzz_match_key
Contribute to CURA-10376
This commit is contained in:
parent
f190b0395d
commit
95962b2914
@ -46,6 +46,7 @@ def main(tmx_source_path: Path, tmx_target_path: Path, i18n_path: Path):
|
|||||||
fuzz_match_key = list(po_content[key_lang].keys())[fuzz_match_ratio.index(fuzz_max_ratio)]
|
fuzz_match_key = list(po_content[key_lang].keys())[fuzz_match_ratio.index(fuzz_max_ratio)]
|
||||||
if fuzz_max_ratio > 90:
|
if fuzz_max_ratio > 90:
|
||||||
fuzz_match_po_value = po_content[key_lang][fuzz_match_key]
|
fuzz_match_po_value = po_content[key_lang][fuzz_match_key]
|
||||||
|
tuvs[0].find("seg").text = fuzz_match_key
|
||||||
tuvs[1].find("seg").text = fuzz_match_po_value
|
tuvs[1].find("seg").text = fuzz_match_po_value
|
||||||
# print(f"[{key_lang}] Fuzz match: {key_source} -> {fuzz_match_key} -> {fuzz_match_po_value} with a ratio of {fuzz_max_ratio}")
|
# print(f"[{key_lang}] Fuzz match: {key_source} -> {fuzz_match_key} -> {fuzz_match_po_value} with a ratio of {fuzz_max_ratio}")
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user