bug 1372167, toml l10n configs for Thunderbird, Calendar, SeaMonkey, r?Fallen
The configs just match what the ini configs do.
For SeaMonkey, there were some bugs in filter.py that I fixed along the
way. Some file path checks were in unreachable parts, and some file
checks were missing.
I intentionally dropped the ignore flags for bad editor backups, too,
those should really just be reported, so that they don't slip in.
Also, most editors don't create those no more.
MozReview-Commit-ID: 6m2yid3nGZq
new file mode 100644
--- /dev/null
+++ b/calendar/locales/l10n.toml
@@ -0,0 +1,89 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+basepath = "../.."
+
+locales = [
+ "ar",
+ "bg",
+ "br",
+ "ca",
+ "cs",
+ "cy",
+ "da",
+ "de",
+ "dsb",
+ "en-GB",
+ "es-AR",
+ "es-ES",
+ "et",
+ "eu",
+ "fi",
+ "fr",
+ "fy-NL",
+ "ga-IE",
+ "gd",
+ "gl",
+ "he",
+ "hr",
+ "hsb",
+ "hu",
+ "id",
+ "is",
+ "it",
+ "ja",
+ "ja-JP-mac",
+ "ka",
+ "kab",
+ "ko",
+ "lt",
+ "nb-NO",
+ "nl",
+ "nn-NO",
+ "pa-IN",
+ "pl",
+ "pt-PT",
+ "rm",
+ "ro",
+ "ru",
+ "sk",
+ "sl",
+ "sq",
+ "sv-SE",
+ "tr",
+ "uk",
+ "zh-CN",
+ "zh-TW",
+]
+
+[env]
+ l = "{l10n_base}/{locale}/"
+
+[[paths]]
+ reference = "calendar/locales/en-US/**"
+ l10n = "{l}calendar/**"
+
+# Timezone properties don't have to be translated
+[[filters]]
+ path = "{l}calendar/chrome/calendar/timezones.properties"
+ key = "re:."
+ action = "warning"
+
+# Noun class entries do not have to be translated
+[[filters]]
+ path = "{l}calendar/chrome/calendar/calendar-event-dialog.properties"
+ key = "re:.*Nounclass[1-9].*"
+ action = "ignore"
+
+# most extraction related strings are not required
+[[filters]]
+ path = "{l}calendar/chrome/calendar/calendar-extract.properties"
+ key = "re:.*from\\.today.*"
+ action = "warning"
+
+# Provider for Google Calendar AMO strings do not have to be translated
+[[filters]]
+ path = "{l}calendar/chrome/calendar/providers/gdata/amo.properties"
+ key = "re:."
+ action = "warning"
new file mode 100644
--- /dev/null
+++ b/mail/locales/l10n.toml
@@ -0,0 +1,122 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+basepath = "../.."
+
+locales = [
+ "af",
+ "ar",
+ "ast",
+ "be",
+ "bg",
+ "bn-BD",
+ "br",
+ "ca",
+ "cs",
+ "cy",
+ "da",
+ "de",
+ "dsb",
+ "el",
+ "en-GB",
+ "es-AR",
+ "es-ES",
+ "et",
+ "eu",
+ "fi",
+ "fr",
+ "fy-NL",
+ "ga-IE",
+ "gd",
+ "gl",
+ "he",
+ "hr",
+ "hsb",
+ "hu",
+ "hy-AM",
+ "id",
+ "is",
+ "it",
+ "ja",
+ "ja-JP-mac",
+ "ka",
+ "kab",
+ "ko",
+ "lt",
+ "nb-NO",
+ "nl",
+ "nn-NO",
+ "pa-IN",
+ "pl",
+ "pt-BR",
+ "pt-PT",
+ "rm",
+ "ro",
+ "ru",
+ "si",
+ "sk",
+ "sl",
+ "sq",
+ "sr",
+ "sv-SE",
+ "ta-LK",
+ "tr",
+ "uk",
+ "vi",
+ "zh-CN",
+ "zh-TW",
+]
+
+[env]
+ l = "{l10n_base}/{locale}/"
+ mozilla = "mozilla"
+
+
+[[paths]]
+ reference = "mail/locales/en-US/**"
+ l10n = "{l}mail/**"
+
+[[paths]]
+ reference = "chat/locales/en-US/**"
+ l10n = "{l}chat/**"
+
+[[paths]]
+ reference = "editor/ui/locales/en-US/**"
+ l10n = "{l}editor/ui/**"
+
+[[paths]]
+ reference = "other-licenses/branding/thunderbird/locales/en-US/**"
+ l10n = "{l}other-licenses/branding/thunderbird/**"
+
+[[includes]]
+ path = "{mozilla}/devtools/client/locales/l10n.toml"
+
+[[includes]]
+ path = "{mozilla}/toolkit/locales/l10n.toml"
+
+
+# ignore MOZ_LANGPACK_CONTRIBUTORS
+[[filters]]
+ path = "{l}mail/defines.inc"
+ key = "MOZ_LANGPACK_CONTRIBUTORS"
+ action = "ignore"
+
+# defines.inc and all-l10n.js can be missing completely
+[[filters]]
+ path = [
+ "{l}mail/defines.inc",
+ "{l}mail/all-l10n.js",
+ ]
+ action = "ignore"
+
+# search prefs don't have the same number for all locales
+[[filters]]
+ path = "{l}mail/chrome/messenger-region/region.properties"
+ key = "re:browser\\.search\\.order\\.[1-9].*"
+ action = "ignore"
+
+# search plugins are different per locale, ignore file difference
+[[filters]]
+ path = "{l}mail/searchplugins/*.xml"
+ action = "ignore"
--- a/suite/locales/filter.py
+++ b/suite/locales/filter.py
@@ -15,24 +15,25 @@ def test(mod, path, entity=None):
re.match(r".+\.(orig|rej)", path)):
return "ignore"
if mod not in ("suite"):
# we only have exceptions for suite
return "error"
if entity is None:
# missing and obsolete files
return ("ignore" if (re.match(r"searchplugins\/.+\.xml", path) or
+ path == "profile/bookmarks.extra" or
+ path == "profile/panels.extra" or
+ path == "defines.inc" or
+ path == "suite-l10n.js" or
re.match(r"chrome\/common\/help\/images\/[A-Za-z-_]+\.[a-z]+", path))
else "error")
if path == "defines.inc":
return ("ignore" if (entity == "MOZ_LANGPACK_CONTRIBUTORS")
else "error")
- if path == "profile/bookmarks.extra" or path == "profile/panels.extra":
- # ignore files for additional bookmarks and panels
- return "ignore"
if path == "chrome/common/region.properties":
return ("ignore" if (re.match(r"browser\.search\.order\.[1-9]", entity))
else "error")
if path != "chrome/browser/region.properties":
# only region.properties exceptions remain, compare all others
return "error"
new file mode 100644
--- /dev/null
+++ b/suite/locales/l10n.toml
@@ -0,0 +1,103 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+basepath = "../.."
+
+locales = [
+ "ca",
+ "cs",
+ "da",
+ "de",
+ "en-GB",
+ "es-AR",
+ "es-ES",
+ "fi",
+ "fr",
+ "gl",
+ "hu",
+ "it",
+ "ja",
+ "ja-JP-mac",
+ "ka",
+ "lt",
+ "nb-NO",
+ "nl",
+ "pl",
+ "pt-BR",
+ "pt-PT",
+ "ro",
+ "ru",
+ "si",
+ "sk",
+ "sv-SE",
+ "tr",
+ "uk",
+ "zh-CN",
+ "zh-TW",
+]
+
+[env]
+ l = "{l10n_base}/{locale}/"
+ mozilla = "mozilla"
+
+
+[[paths]]
+ reference = "suite/locales/en-US/**"
+ l10n = "{l}suite/**"
+
+[[paths]]
+ reference = "editor/ui/locales/en-US/**"
+ l10n = "{l}editor/ui/**"
+
+[[paths]]
+ reference = "{mozilla}/services/sync/locales/en-US/**"
+ l10n = "{l}services/sync/**"
+
+
+[[includes]]
+ path = "{mozilla}/devtools/client/locales/l10n.toml"
+
+[[includes]]
+ path = "{mozilla}/toolkit/locales/l10n.toml"
+
+
+# ignore MOZ_LANGPACK_CONTRIBUTORS
+[[filters]]
+ path = "{l}suite/defines.inc"
+ key = "MOZ_LANGPACK_CONTRIBUTORS"
+ action = "ignore"
+
+# defines.inc and all-l10n.js can be missing completely
+[[filters]]
+ path = [
+ "{l}suite/defines.inc",
+ "{l}suite/suite-l10n.js",
+ ]
+ action = "ignore"
+
+# search prefs don't have the same number for all locales
+[[filters]]
+ path = "{l}suite/chrome/common/region.properties"
+ key = "re:browser\\.search\\.order\\.[1-9].*"
+ action = "ignore"
+
+# content handler prefs don't have the same number for all locales
+[[filters]]
+ path = "{l}suite/chrome/browser/region.properties"
+ key = "re:browser\\.contentHandlers\\.types\\.[0-5].*"
+ action = "ignore"
+
+# search plugins are different per locale, ignore file difference
+[[filters]]
+ path = "{l}suite/searchplugins/*.xml"
+ action = "ignore"
+
+# extra data and help images are optional
+[[filters]]
+ path = [
+ "{l}suite/profile/bookmarks.extra",
+ "{l}suite/profile/panels.extra",
+ "{l}suite/chrome/common/help/images/*.*",
+ ]
+ action = "ignore"