diff options
author | Remko Tronçon <git@el-tramo.be> | 2011-04-12 17:12:42 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2011-04-12 17:59:55 (GMT) |
commit | 572f5fd7af0c0a59440e215d7cc074fd637ef32a (patch) | |
tree | ea9c210371d5fab85aa38db4bf6c30bef6e53bf3 /BuildTools | |
parent | fc8408fe038dd26296d966af061b7f7393c719cd (diff) | |
download | swift-572f5fd7af0c0a59440e215d7cc074fd637ef32a.zip swift-572f5fd7af0c0a59440e215d7cc074fd637ef32a.tar.bz2 |
Updated German translation & added french translation.
Release-Notes: Added French translation (Thanks to Cédric Dubouloz)
Diffstat (limited to 'BuildTools')
-rwxr-xr-x | BuildTools/CheckTranslations.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/BuildTools/CheckTranslations.py b/BuildTools/CheckTranslations.py index 5796bac..8dcf414 100755 --- a/BuildTools/CheckTranslations.py +++ b/BuildTools/CheckTranslations.py @@ -14,6 +14,7 @@ for filename in os.listdir("Swift/Translations") : m = re.match("swift_(.*)\.ts", filename) if m : language = m.group(1) + finished = True f = open("Swift/Translations/" + filename, "r") document = xml.dom.minidom.parse(f) f.close() @@ -23,7 +24,11 @@ for filename in os.listdir("Swift/Translations") : sourceText = getText(source.childNodes) sourcePlaceholders = set(re.findall("%\d+%?", sourceText)) translation = message.getElementsByTagName("translation")[0] + if "type" in translation.attributes.keys() and translation.attributes["type"]. value == "unfinished" : + finished = False translationText = getText(translation.childNodes) translationPlaceholders = set(re.findall("%\d+%?", translationText)) if translationPlaceholders != sourcePlaceholders : print "[Error] " + filename + ": Placeholder mismatch in translation '" + sourceText + "'" + if not finished : + print "[Warning] " + filename + ": Unfinished" |