Add translations check script (#34272)
This commit is contained in:
1 parent
d011b46985
commit
1ffc3a00e7
13 files changed
+106
-40
No files matched your search
@@ -21,9 +21,7 @@ def main():
|
||||
args = get_arguments()
|
||||
|
||||
module = importlib.import_module(f".{args.action}", "script.translations")
|
||||
module.run()
|
||||
|
||||
return 0
|
||||
return module.run()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
@@ -68,3 +68,5 @@ def run():
|
||||
|
||||
print("Deleting keys:", ", ".join(map(str, to_delete)))
|
||||
print(lokalise.keys_delete_multiple(to_delete))
|
||||
|
||||
return 0
|
||||
@@ -61,3 +61,5 @@ def run():
|
||||
)
|
||||
|
||||
download.write_integration_translations()
|
||||
|
||||
return 0
|
||||
@@ -149,3 +149,5 @@ def run():
|
||||
run_download_docker()
|
||||
|
||||
write_integration_translations()
|
||||
|
||||
return 0
|
||||
@@ -48,3 +48,5 @@ def run():
|
||||
print()
|
||||
print("Updating keys")
|
||||
pprint(lokalise.keys_bulk_update(updates).json())
|
||||
|
||||
return 0
|
||||
@@ -82,3 +82,5 @@ def run():
|
||||
LOCAL_FILE.write_text(json.dumps(translations, indent=4, sort_keys=True))
|
||||
|
||||
run_upload_docker()
|
||||
|
||||
return 0
|
||||
@@ -13,7 +13,7 @@ def get_base_arg_parser():
|
||||
parser.add_argument(
|
||||
"action",
|
||||
type=str,
|
||||
choices=["download", "clean", "upload", "develop", "migrate"],
|
||||
choices=["clean", "develop", "download", "migrate", "upload"],
|
||||
)
|
||||
parser.add_argument("--debug", action="store_true", help="Enable log output")
|
||||
return parser
|
||||
|
||||
Reference in new issue
Block a user