Bug 1424683 - Introduce brand.ftl and migrate brand-short-name to it. r=Pike

MozReview-Commit-ID: Cl0jQEkuD8q

--HG--
extra : rebase_source : 6c183503c1f4e693229aa5afface4f8a9f991ea5
This commit is contained in:
Zibi Braniecki 2017-12-18 21:46:49 -08:00
parent 469daa3a6c
commit 551e153581
9 changed files with 94 additions and 0 deletions

View File

@ -0,0 +1,15 @@
# 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/.
## Firefox Brand
##
## Firefox must be treated as a brand, and kept in English.
## It cannot be:
## - Declined to adapt to grammatical case.
## - Transliterated.
## - Translated.
##
## Reference: https://www.mozilla.org/styleguide/communications/translation/
-brand-short-name = Firefox Developer Edition

View File

@ -3,6 +3,8 @@
# 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/.
[localization] @AB_CD@.jar:
branding (en-US/**/*.ftl)
@AB_CD@.jar:
% locale branding @AB_CD@ %locale/branding/

View File

@ -0,0 +1,15 @@
# 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/.
## Firefox Brand
##
## Firefox must be treated as a brand, and kept in English.
## It cannot be:
## - Declined to adapt to grammatical case.
## - Transliterated.
## - Translated.
##
## Reference: https://www.mozilla.org/styleguide/communications/translation/
-brand-short-name = Nightly

View File

@ -3,6 +3,8 @@
# 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/.
[localization] @AB_CD@.jar:
branding (en-US/**/*.ftl)
@AB_CD@.jar:
% locale branding @AB_CD@ %locale/branding/

View File

@ -0,0 +1,15 @@
# 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/.
## Firefox Brand
##
## Firefox must be treated as a brand, and kept in English.
## It cannot be:
## - Declined to adapt to grammatical case.
## - Transliterated.
## - Translated.
##
## Reference: https://www.mozilla.org/styleguide/communications/translation/
-brand-short-name = Firefox

View File

@ -3,6 +3,8 @@
# 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/.
[localization] @AB_CD@.jar:
branding (%*.ftl)
@AB_CD@.jar:
% locale branding @AB_CD@ %locale/branding/

View File

@ -0,0 +1,15 @@
# 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/.
## Firefox Brand
##
## Firefox must be treated as a brand, and kept in English.
## It cannot be:
## - Declined to adapt to grammatical case.
## - Transliterated.
## - Translated.
##
## Reference: https://www.mozilla.org/styleguide/communications/translation/
-brand-short-name = Nightly

View File

@ -3,6 +3,8 @@
# 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/.
[localization] @AB_CD@.jar:
branding (en-US/**/*.ftl)
@AB_CD@.jar:
% locale branding @AB_CD@ %locale/branding/

View File

@ -0,0 +1,26 @@
# coding=utf8
# Any copyright is dedicated to the Public Domain.
# http://creativecommons.org/publicdomain/zero/1.0/
from __future__ import absolute_import
import fluent.syntax.ast as FTL
from fluent.migrate import COPY
def migrate(ctx):
"""Bug 1424683 - Migrate brand-short-name to Fluent, part {index}."""
ctx.add_transforms(
'browser/branding/official/brand.ftl',
'browser/branding/official/locales/en-US/brand.ftl',
[
FTL.Term(
id=FTL.Identifier('-brand-short-name'),
value=COPY(
'browser/branding/official/brand.dtd',
'brandShortName'
)
),
]
)