1
0
Fork 0
mirror of https://github.com/YunoHost/apps.git synced 2024-09-03 20:06:07 +02:00

[enh] prevent generate_translation_file.py to be run more than once

This commit is contained in:
Laurent Peuch 2017-03-07 00:51:05 +01:00
parent f5f7b80062
commit 6bfee7b4da

View file

@ -4,6 +4,11 @@ import json
if __name__ == '__main__': if __name__ == '__main__':
if os.path.exists("locales/en.json"):
print "This script should be run only once, the first time to generate locales/, after that you should use update_translations.py"
print "Abort"
sys.exit(1)
builded_file = json.load(open(sys.argv[1], "r")) builded_file = json.load(open(sys.argv[1], "r"))
other_langs = {} other_langs = {}