From 2f8f8c78f78ee2581bb994f98bc2daddfbe9d508 Mon Sep 17 00:00:00 2001 From: Luc Charland Date: Fri, 31 Jul 2015 13:54:03 -0400 Subject: [PATCH] Removing colons --- Scripts/verify_translations.py | 24 +++--- .../Arabic.lproj/Localizable.strings | 14 ++-- .../Basque.lproj/Localizable.strings | 12 +-- .../Localizable.strings | 14 ++-- .../Catalan.lproj/Localizable.strings | 14 ++-- .../ChineseTaiwan.lproj/Localizable.strings | 14 ++-- .../Czech.lproj/Localizable.strings | 14 ++-- .../Danish.lproj/Localizable.strings | 14 ++-- .../Dutch.lproj/Localizable.strings | 14 ++-- .../English.lproj/Localizable.strings | 14 ++-- .../Finnish.lproj/Localizable.strings | 14 ++-- .../French.lproj/Localizable.strings | 14 ++-- .../German.lproj/Localizable.strings | 14 ++-- .../Hungarian.lproj/Localizable.strings | 14 ++-- .../Icelandic.lproj/Localizable.strings | 6 +- .../Italian.lproj/Localizable.strings | 6 +- .../NorwegianBokmal.lproj/Localizable.strings | 14 ++-- .../Localizable.strings | 6 +- .../Polish.lproj/Localizable.strings | 14 ++-- .../Russian.lproj/Localizable.strings | 14 ++-- .../Slovak.lproj/Localizable.strings | 14 ++-- .../Slovenian.lproj/Localizable.strings | 14 ++-- .../Localizable.strings | 14 ++-- .../SpanishSpain.lproj/Localizable.strings | 14 ++-- .../Swedish.lproj/Localizable.strings | 6 +- .../Ukrainian.lproj/Localizable.strings | 6 +- .../Welsh.lproj/Localizable.strings | 6 +- UI/Contacts/Arabic.lproj/Localizable.strings | 26 +++---- UI/Contacts/Basque.lproj/Localizable.strings | 26 +++---- .../Localizable.strings | 26 +++---- UI/Contacts/Catalan.lproj/Localizable.strings | 26 +++---- .../ChineseTaiwan.lproj/Localizable.strings | 26 +++---- UI/Contacts/Czech.lproj/Localizable.strings | 26 +++---- UI/Contacts/Danish.lproj/Localizable.strings | 26 +++---- UI/Contacts/Dutch.lproj/Localizable.strings | 26 +++---- UI/Contacts/English.lproj/Localizable.strings | 26 +++---- UI/Contacts/Finnish.lproj/Localizable.strings | 26 +++---- UI/Contacts/French.lproj/Localizable.strings | 26 +++---- UI/Contacts/German.lproj/Localizable.strings | 26 +++---- .../Hungarian.lproj/Localizable.strings | 26 +++---- .../Icelandic.lproj/Localizable.strings | 26 +++---- UI/Contacts/Italian.lproj/Localizable.strings | 26 +++---- .../NorwegianBokmal.lproj/Localizable.strings | 26 +++---- .../Localizable.strings | 26 +++---- UI/Contacts/Polish.lproj/Localizable.strings | 26 +++---- UI/Contacts/Russian.lproj/Localizable.strings | 26 +++---- UI/Contacts/Slovak.lproj/Localizable.strings | 26 +++---- .../Slovenian.lproj/Localizable.strings | 26 +++---- .../Localizable.strings | 26 +++---- .../SpanishSpain.lproj/Localizable.strings | 26 +++---- UI/Contacts/Swedish.lproj/Localizable.strings | 26 +++---- .../Ukrainian.lproj/Localizable.strings | 26 +++---- UI/Contacts/Welsh.lproj/Localizable.strings | 22 +++--- UI/MailerUI/Arabic.lproj/Localizable.strings | 4 +- UI/MailerUI/Basque.lproj/Localizable.strings | 6 +- .../Localizable.strings | 6 +- UI/MailerUI/Catalan.lproj/Localizable.strings | 4 +- .../ChineseTaiwan.lproj/Localizable.strings | 6 +- UI/MailerUI/Czech.lproj/Localizable.strings | 6 +- UI/MailerUI/Danish.lproj/Localizable.strings | 4 +- UI/MailerUI/Dutch.lproj/Localizable.strings | 6 +- UI/MailerUI/English.lproj/Localizable.strings | 6 +- UI/MailerUI/Finnish.lproj/Localizable.strings | 6 +- UI/MailerUI/French.lproj/Localizable.strings | 6 +- UI/MailerUI/German.lproj/Localizable.strings | 6 +- .../Hungarian.lproj/Localizable.strings | 6 +- .../Icelandic.lproj/Localizable.strings | 4 +- UI/MailerUI/Italian.lproj/Localizable.strings | 4 +- .../NorwegianBokmal.lproj/Localizable.strings | 6 +- .../Localizable.strings | 4 +- UI/MailerUI/Polish.lproj/Localizable.strings | 6 +- UI/MailerUI/Russian.lproj/Localizable.strings | 6 +- UI/MailerUI/Slovak.lproj/Localizable.strings | 4 +- .../Slovenian.lproj/Localizable.strings | 6 +- .../Localizable.strings | 6 +- .../SpanishSpain.lproj/Localizable.strings | 6 +- UI/MailerUI/Swedish.lproj/Localizable.strings | 4 +- .../Ukrainian.lproj/Localizable.strings | 4 +- UI/MailerUI/Welsh.lproj/Localizable.strings | 4 +- UI/MainUI/Arabic.lproj/Localizable.strings | 8 +- UI/MainUI/Basque.lproj/Localizable.strings | 8 +- .../Localizable.strings | 8 +- UI/MainUI/Catalan.lproj/Localizable.strings | 8 +- .../ChineseTaiwan.lproj/Localizable.strings | 8 +- UI/MainUI/Czech.lproj/Localizable.strings | 8 +- UI/MainUI/Danish.lproj/Localizable.strings | 8 +- UI/MainUI/Dutch.lproj/Localizable.strings | 8 +- UI/MainUI/English.lproj/Localizable.strings | 8 +- UI/MainUI/Finnish.lproj/Localizable.strings | 8 +- UI/MainUI/French.lproj/Localizable.strings | 8 +- UI/MainUI/German.lproj/Localizable.strings | 8 +- UI/MainUI/Hungarian.lproj/Localizable.strings | 8 +- UI/MainUI/Icelandic.lproj/Localizable.strings | 8 +- UI/MainUI/Italian.lproj/Localizable.strings | 8 +- .../NorwegianBokmal.lproj/Localizable.strings | 8 +- .../Localizable.strings | 8 +- UI/MainUI/Polish.lproj/Localizable.strings | 8 +- UI/MainUI/Russian.lproj/Localizable.strings | 8 +- UI/MainUI/Slovak.lproj/Localizable.strings | 8 +- UI/MainUI/Slovenian.lproj/Localizable.strings | 8 +- .../Localizable.strings | 8 +- .../SpanishSpain.lproj/Localizable.strings | 8 +- UI/MainUI/Swedish.lproj/Localizable.strings | 8 +- UI/MainUI/Ukrainian.lproj/Localizable.strings | 8 +- UI/MainUI/Welsh.lproj/Localizable.strings | 8 +- .../Arabic.lproj/Localizable.strings | 68 ++++++++--------- .../Basque.lproj/Localizable.strings | 74 +++++++++---------- .../Localizable.strings | 74 +++++++++---------- .../Catalan.lproj/Localizable.strings | 72 +++++++++--------- .../ChineseTaiwan.lproj/Localizable.strings | 74 +++++++++---------- .../Czech.lproj/Localizable.strings | 74 +++++++++---------- .../Danish.lproj/Localizable.strings | 70 +++++++++--------- .../Dutch.lproj/Localizable.strings | 74 +++++++++---------- .../English.lproj/Localizable.strings | 74 +++++++++---------- .../Finnish.lproj/Localizable.strings | 74 +++++++++---------- .../French.lproj/Localizable.strings | 74 +++++++++---------- .../German.lproj/Localizable.strings | 74 +++++++++---------- .../Hungarian.lproj/Localizable.strings | 74 +++++++++---------- .../Icelandic.lproj/Localizable.strings | 68 ++++++++--------- .../Italian.lproj/Localizable.strings | 64 ++++++++-------- .../NorwegianBokmal.lproj/Localizable.strings | 74 +++++++++---------- .../Localizable.strings | 74 +++++++++---------- .../Polish.lproj/Localizable.strings | 74 +++++++++---------- .../Russian.lproj/Localizable.strings | 74 +++++++++---------- .../Slovak.lproj/Localizable.strings | 70 +++++++++--------- .../Slovenian.lproj/Localizable.strings | 74 +++++++++---------- .../Localizable.strings | 74 +++++++++---------- .../SpanishSpain.lproj/Localizable.strings | 74 +++++++++---------- .../Swedish.lproj/Localizable.strings | 74 +++++++++---------- .../Ukrainian.lproj/Localizable.strings | 72 +++++++++--------- .../Welsh.lproj/Localizable.strings | 74 +++++++++---------- UI/Scheduler/Arabic.lproj/Localizable.strings | 42 +++++------ UI/Scheduler/Basque.lproj/Localizable.strings | 56 +++++++------- .../Localizable.strings | 50 ++++++------- .../Catalan.lproj/Localizable.strings | 52 ++++++------- .../ChineseTaiwan.lproj/Localizable.strings | 52 ++++++------- UI/Scheduler/Czech.lproj/Localizable.strings | 50 ++++++------- UI/Scheduler/Danish.lproj/Localizable.strings | 42 +++++------ UI/Scheduler/Dutch.lproj/Localizable.strings | 50 ++++++------- .../English.lproj/Localizable.strings | 50 ++++++------- .../Finnish.lproj/Localizable.strings | 50 ++++++------- UI/Scheduler/French.lproj/Localizable.strings | 50 ++++++------- UI/Scheduler/German.lproj/Localizable.strings | 50 ++++++------- .../Hungarian.lproj/Localizable.strings | 52 ++++++------- .../Icelandic.lproj/Localizable.strings | 40 +++++----- .../Italian.lproj/Localizable.strings | 42 +++++------ .../NorwegianBokmal.lproj/Localizable.strings | 50 ++++++------- .../Localizable.strings | 40 +++++----- UI/Scheduler/Polish.lproj/Localizable.strings | 50 ++++++------- .../Russian.lproj/Localizable.strings | 50 ++++++------- UI/Scheduler/Slovak.lproj/Localizable.strings | 50 ++++++------- .../Slovenian.lproj/Localizable.strings | 50 ++++++------- .../Localizable.strings | 52 ++++++------- .../SpanishSpain.lproj/Localizable.strings | 52 ++++++------- .../Swedish.lproj/Localizable.strings | 40 +++++----- .../Ukrainian.lproj/Localizable.strings | 40 +++++----- UI/Scheduler/Welsh.lproj/Localizable.strings | 40 +++++----- .../Appointments/SOGoAptMailReceipt.wox | 6 +- .../ContactsUI/UIxContactEditorTemplate.wox | 2 +- .../UIxContactFolderLinksTemplate.wox | 4 +- UI/Templates/ContactsUI/UIxListEditor.wox | 6 +- UI/Templates/MailerUI/UIxMailMainFrame.wox | 2 +- UI/Templates/MailerUI/UIxMailSearch.wox | 2 +- UI/Templates/MainUI/SOGoRootPage.wox | 8 +- .../PreferencesUI/UIxAccountEditor.wox | 28 +++---- UI/Templates/PreferencesUI/UIxPreferences.wox | 54 +++++++------- .../SchedulerUI/UIxAppointmentEditor.wox | 14 ++-- .../UIxAppointmentEditorTemplate.wox | 4 +- .../UIxAppointmentViewTemplate.wox | 6 +- .../SchedulerUI/UIxCalFilterPanel.wox | 2 +- UI/Templates/SchedulerUI/UIxCalMainView.wox | 6 +- UI/Templates/SchedulerUI/UIxCalViewPrint.wox | 8 +- .../UIxCalendarFolderLinksTemplate.wox | 4 +- .../SchedulerUI/UIxComponentEditor.wox | 50 ++++++------- UI/Templates/SchedulerUI/UIxTaskEditor.wox | 12 +-- .../SchedulerUI/UIxTaskEditorTemplate.wox | 4 +- .../SchedulerUI/UIxTaskViewTemplate.wox | 4 +- UI/WebServerResources/angular-material | 2 +- 178 files changed, 2360 insertions(+), 2354 deletions(-) diff --git a/Scripts/verify_translations.py b/Scripts/verify_translations.py index f5ca644f1..cf06585b7 100755 --- a/Scripts/verify_translations.py +++ b/Scripts/verify_translations.py @@ -21,11 +21,12 @@ def get_translations(path): try: transpath = dir_mappings.get(path, path) transname = transpath + '/English.lproj/Localizable.strings' - transall = open(transname).read().split('\n') - transgood = [l.strip() for l in transall if len(l.strip()) and l.strip()[0] != '#'] + #transall = open(transname).read().split('\n') + #transgood = [l.strip() for l in transall if len(l.strip()) and l.strip()[0] != '#'] + transall = open(transname).read() except: - transgood = () - return transgood + transall = "" + return transall def find_missing_translations(rootdir='.', extention='', recomp=None, greylist=()): @@ -38,8 +39,7 @@ def find_missing_translations(rootdir='.', extention='', recomp=None, greylist=( continue pathname = path + '/' + filename lines = open(pathname).read().split("\n") - regex_results = [recomp.search(l) for l in lines] - values = [r.groups()[0] for r in regex_results if r] + values = [r.groups()[0] for r in [recomp.search(l) for l in lines] if r] if values: #- Get the current english translations for the path transgood = get_translations(path) @@ -50,9 +50,15 @@ def find_missing_translations(rootdir='.', extention='', recomp=None, greylist=( if DEBUG:print pathname for value in values: #- Try to find the value from the source file in the translation file - found = [line for line in transgood if value in line] + #compvalue = re.compile('"(%s)"\s=\s"(.*?)";' % value) + escaped_value = re.escape(value) + found = re.search('(%s|"%s")\s*=\s*"(.*?)";' % (escaped_value, escaped_value), transgood) + #for line in transgood: + # found = compvalue.search(line) + # if found: + # break if found: - if DEBUG: print "\t", "[%s] FOUND --" % value, found[0].split("=")[0] + if DEBUG: print "\t", '[%s] FOUND -- "%s"' % found.groups() else: notfound.append("-->\t[%s] ==== Not Found ====" % value) if notfound: @@ -73,7 +79,7 @@ def main(): greylist = ('UIxFilterEditor.wox') #- Get only the label:value from all lines - recomp = re.compile(' + label:value="The following attendees(s) were notified" const:escapeHTML="NO"/> @@ -54,7 +54,7 @@ th, td { font-family: Lucida Grande, Bitstream VeraSans, Tahoma, sans-serif; fon > + label:value="The following attendees(s) were added" const:escapeHTML="NO"/> @@ -67,7 +67,7 @@ th, td { font-family: Lucida Grande, Bitstream VeraSans, Tahoma, sans-serif; fon > + label:value="The following attendees(s) were removed" const:escapeHTML="NO"/> diff --git a/UI/Templates/ContactsUI/UIxContactEditorTemplate.wox b/UI/Templates/ContactsUI/UIxContactEditorTemplate.wox index ff35ff34c..743e0e3bd 100644 --- a/UI/Templates/ContactsUI/UIxContactEditorTemplate.wox +++ b/UI/Templates/ContactsUI/UIxContactEditorTemplate.wox @@ -312,7 +312,7 @@
- +
@@ -31,7 +31,7 @@
- +
diff --git a/UI/Templates/ContactsUI/UIxListEditor.wox b/UI/Templates/ContactsUI/UIxListEditor.wox index d82e9cc89..7f30d24cd 100644 --- a/UI/Templates/ContactsUI/UIxListEditor.wox +++ b/UI/Templates/ContactsUI/UIxListEditor.wox @@ -20,13 +20,13 @@
- +
- + - +
diff --git a/UI/Templates/MailerUI/UIxMailMainFrame.wox b/UI/Templates/MailerUI/UIxMailMainFrame.wox index 1f9af989b..86c389fc5 100644 --- a/UI/Templates/MailerUI/UIxMailMainFrame.wox +++ b/UI/Templates/MailerUI/UIxMailMainFrame.wox @@ -265,7 +265,7 @@ - + {{warning}}
@@ -81,7 +81,7 @@
@@ -97,7 +97,7 @@
diff --git a/UI/Templates/PreferencesUI/UIxAccountEditor.wox b/UI/Templates/PreferencesUI/UIxAccountEditor.wox index 37766329a..014cdd635 100644 --- a/UI/Templates/PreferencesUI/UIxAccountEditor.wox +++ b/UI/Templates/PreferencesUI/UIxAccountEditor.wox @@ -15,24 +15,24 @@ - + - + - + - + @@ -40,50 +40,50 @@ - + - + - + - + - + - + - +