tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

l10n.rst (1502B)


      1 L10n
      2 ====
      3 
      4 The l10n linter checks for mistakes and problems in the localizable files.
      5 Most of the code lives inside the
      6 `compare-locales <https://pypi.org/project/compare-locales/>`_
      7 package, and is shipping as the ``moz-l10n-lint`` command.
      8 
      9 The linter checks for fundamental issues like parsing errors, but it also
     10 finds more subtle mistakes like duplicated messages. It also warns if you're
     11 trying to change a string without changing the ID, or to add a string that's
     12 still in use in a stable channel with a different value.
     13 
     14 The warnings on string ID changes get reported on phabricator, but they're
     15 not making the build fail. To find out when to change IDs and when not to,
     16 read the :ref:`Lifecycle & Workflow <Localization>` section in the
     17 localization documentation.
     18 
     19 Run Locally
     20 -----------
     21 
     22 The can be run using mach:
     23 
     24 .. parsed-literal::
     25 
     26    $ mach lint --linter l10n <file paths>
     27 
     28 Alternatively, omit the ``--linter l10n`` and run all configured linters, which
     29 will include the l10n linter.
     30 
     31 
     32 Updating the Reference
     33 ----------------------
     34 
     35 The linter checks out the ``firefox-l10n-source`` localization files into your
     36 ``.mozbuild`` state directory. By default this is updated automatically after
     37 48 hours. There might be new strings anyway, if you want to ensure an
     38 updated clone, remove the marker file in
     39 ``~/.mozbuild/l10n-source/.git/l10n_pull_marker``.
     40 
     41 Sources
     42 -------
     43 
     44 * :searchfox:`Configuration (YAML) <tools/lint/l10n.yml>`
     45 * :searchfox:`Source <tools/lint/python/l10n_lint.py>`