From f5022069609fb3b687b694ad6e32f2b60483b2a0 Mon Sep 17 00:00:00 2001 From: "Francesco Lodolo (:flod)" Date: Thu, 15 Nov 2018 12:48:09 +0000 Subject: [PATCH] Bug 1507441 - Replace FTL.VariantName with FTL.Identifier in existing recipes and documentation, fix nits in recipes r=stas Differential Revision: https://phabricator.services.mozilla.com/D12001 --HG-- extra : moz-landing-system : lando --- intl/l10n/docs/fluent_migrations.rst | 2 +- .../bug_1486934_aboutAbout.py | 2 +- .../bug_1486935_aboutprofiles.py | 8 +++---- .../bug_1486937_abouturlclassifier.py | 2 +- .../bug_1491676_preferences_properties.py | 20 ++++++++-------- .../bug_1491677_extensions.py | 24 +++++++++---------- .../bug_1501900_aboutdevtools.py | 2 +- 7 files changed, 30 insertions(+), 30 deletions(-) diff --git a/intl/l10n/docs/fluent_migrations.rst b/intl/l10n/docs/fluent_migrations.rst index 77a7096992130..92a31046cec6d 100644 --- a/intl/l10n/docs/fluent_migrations.rst +++ b/intl/l10n/docs/fluent_migrations.rst @@ -487,7 +487,7 @@ category used in plural forms. For these reasons, it’s not possible to use ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "browser/chrome/browser/preferences/main.dtd", diff --git a/python/l10n/fluent_migrations/bug_1486934_aboutAbout.py b/python/l10n/fluent_migrations/bug_1486934_aboutAbout.py index 8422e314326b2..ecfd34a601894 100644 --- a/python/l10n/fluent_migrations/bug_1486934_aboutAbout.py +++ b/python/l10n/fluent_migrations/bug_1486934_aboutAbout.py @@ -8,7 +8,7 @@ from fluent.migrate.helpers import transforms_from def migrate(ctx): - """Bug 1486934 - Modify about:about to use fluent for localization, part {index}.""" + """Bug 1486934 - Modify about:about to use Fluent for localization, part {index}.""" ctx.add_transforms( "toolkit/toolkit/about/aboutAbout.ftl", diff --git a/python/l10n/fluent_migrations/bug_1486935_aboutprofiles.py b/python/l10n/fluent_migrations/bug_1486935_aboutprofiles.py index e95eb0af78aa8..e6e53336e9748 100644 --- a/python/l10n/fluent_migrations/bug_1486935_aboutprofiles.py +++ b/python/l10n/fluent_migrations/bug_1486935_aboutprofiles.py @@ -7,7 +7,7 @@ def migrate(ctx): - """ Bug 1486935 - Migrate about:Profiles strings to FTL, part {index}. """ + """ Bug 1486935 - Migrate about:profiles to Fluent, part {index}. """ ctx.add_transforms( "toolkit/toolkit/about/aboutProfiles.ftl", @@ -105,7 +105,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("macos"), + key=FTL.Identifier("macos"), default=False, value=COPY( "toolkit/chrome/global/aboutProfiles.properties", @@ -113,7 +113,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/global/aboutProfiles.properties", @@ -121,7 +121,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/global/aboutProfiles.properties", diff --git a/python/l10n/fluent_migrations/bug_1486937_abouturlclassifier.py b/python/l10n/fluent_migrations/bug_1486937_abouturlclassifier.py index 7d13e9b8dfebf..65c476b0f694a 100644 --- a/python/l10n/fluent_migrations/bug_1486937_abouturlclassifier.py +++ b/python/l10n/fluent_migrations/bug_1486937_abouturlclassifier.py @@ -11,7 +11,7 @@ def migrate(ctx): - """Bug 1486937 - Use fluent for about:url-classifier""" + """Bug 1486937 - Migrate about:url-classifier to Fluent, part {index}.""" ctx.add_transforms( "toolkit/toolkit/about/url-classifier.ftl", diff --git a/python/l10n/fluent_migrations/bug_1491676_preferences_properties.py b/python/l10n/fluent_migrations/bug_1491676_preferences_properties.py index 94ebefc4bb764..22a0768039c68 100644 --- a/python/l10n/fluent_migrations/bug_1491676_preferences_properties.py +++ b/python/l10n/fluent_migrations/bug_1491676_preferences_properties.py @@ -11,7 +11,7 @@ def migrate(ctx): - """Bug 1486937 - Move strings from preferences.properties to Fluent""" + """Bug 1491676 - Move strings from preferences.properties to Fluent""" ctx.add_transforms( "toolkit/toolkit/preferences/preferences.ftl", @@ -23,9 +23,9 @@ def migrate(ctx): failed-pw-change = { COPY(from_path, "failed_pw_change") } incorrect-pw = { COPY(from_path, "incorrect_pw") } pw-empty-warning = { COPY(from_path, "pw_empty_warning") } -pw-change-ok = { COPY(from_path, "pw_change_ok") } { -pw-empty-warning } -pw-erased-ok = { COPY(from_path, "pw_erased_ok") } { -pw-empty-warning } -pw-not-wanted = { COPY(from_path, "pw_not_wanted") } +pw-change-ok = { COPY(from_path, "pw_change_ok") } +pw-erased-ok = { COPY(from_path, "pw_erased_ok") } { pw-empty-warning } +pw-not-wanted = { COPY(from_path, "pw_not_wanted") } { pw-empty-warning } pw-change2empty-in-fips-mode = { COPY(from_path, "pw_change2empty_in_fips_mode") } pw-change-success-title = { COPY(from_path, "pw_change_success_title") } pw-change-failed-title = { COPY(from_path, "pw_change_failed_title") } @@ -79,7 +79,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "browser/chrome/browser/preferences/preferences.properties", @@ -87,7 +87,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "browser/chrome/browser/preferences/preferences.properties", @@ -111,7 +111,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "browser/chrome/browser/preferences/preferences.properties", @@ -119,7 +119,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "browser/chrome/browser/preferences/preferences.properties", @@ -145,7 +145,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=REPLACE( "browser/chrome/browser/preferences/preferences.properties", @@ -158,7 +158,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=REPLACE( "browser/chrome/browser/preferences/preferences.properties", diff --git a/python/l10n/fluent_migrations/bug_1491677_extensions.py b/python/l10n/fluent_migrations/bug_1491677_extensions.py index aa0f4992dd383..7bcd61f46bc11 100644 --- a/python/l10n/fluent_migrations/bug_1491677_extensions.py +++ b/python/l10n/fluent_migrations/bug_1491677_extensions.py @@ -120,7 +120,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=REPLACE( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -131,7 +131,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=REPLACE( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -161,7 +161,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -169,7 +169,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -193,7 +193,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -201,7 +201,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -271,7 +271,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -279,7 +279,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -303,7 +303,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -311,7 +311,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -335,7 +335,7 @@ def migrate(ctx): ), variants=[ FTL.Variant( - key=FTL.VariantName("windows"), + key=FTL.Identifier("windows"), default=False, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", @@ -343,7 +343,7 @@ def migrate(ctx): ) ), FTL.Variant( - key=FTL.VariantName("other"), + key=FTL.Identifier("other"), default=True, value=COPY( "toolkit/chrome/mozapps/extensions/extensions.dtd", diff --git a/python/l10n/fluent_migrations/bug_1501900_aboutdevtools.py b/python/l10n/fluent_migrations/bug_1501900_aboutdevtools.py index 6c9850c2094c3..e9c90a2e5045e 100644 --- a/python/l10n/fluent_migrations/bug_1501900_aboutdevtools.py +++ b/python/l10n/fluent_migrations/bug_1501900_aboutdevtools.py @@ -9,7 +9,7 @@ from fluent.migrate import CONCAT def migrate(ctx): - """Bug 1501900 - Migrate aboutdevtools to Fluent, part {index}""" + """Bug 1501900 - Migrate about:devtools to Fluent, part {index}""" ctx.add_transforms( "devtools/startup/aboutDevTools.ftl",