##// END OF EJS Templates
i18n: updated translation for Polish...
i18n: updated translation for Polish Currently translated at 56.5% (614 of 1087 strings)

File last commit:

r8089:01aca0a4 default
r8092:7fef5132 default
Show More
how_to
120 lines | 4.5 KiB | text/plain | TextLexer
Andrew Shadura
docs: update the translation howto...
r4959 ============
Translations
============
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Translations are available on Hosted Weblate at the following URL:
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
Update i18n howto: we now use Hosted Weblate.
r4676 https://hosted.weblate.org/projects/kallithea/kallithea/
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Registered users may contribute to the existing languages, or request a new
Thomas De Schampheleire
i18n/how_to: fix typos
r7769 language translation.
Andrew Shadura
docs: update the translation howto...
r4959
Mads Kiilerich
docs: consistent spacing around headings...
r5433
Andrew Shadura
docs: update the translation howto...
r4959 Translating using Weblate
-------------------------
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Weblate_ offers a simple and easy to use interface featuring glossary, machine
translation, suggestions based on similar translations in other projects,
automatic checks etc. Weblate imports the source code tree directly from
the version control system, and commits edits back from time to time.
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 When registering at Weblate, make sure you use the name and email address you
prefer to be used when your changes are committed. We can and probably will
amend changesets coming from Weblate, but having things right from the beginning
makes things easier.
Andrew Shadura
docs: update the translation howto...
r4959
Weblate performs sanity checks all the time and tries to prevent you from ignoring
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 them. Most common mistakes are inconsistent punctuation, whitespace, missing or extra
Andrew Shadura
docs: update the translation howto...
r4959 format parameters, untranslated strings copied into the translation. Please perform
necessary corrections when they're needed, or override the false positives.
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
docs: consistent spacing around headings...
r5433
Thomas De Schampheleire
i18n: how_to: add instructions to regenerate translations...
r7486 Merging translations from Weblate (admin-only)
----------------------------------------------
Andrew Shadura
docs: update the translation howto...
r4959
Weblate rebases its changes every time it pulls from our repository. Pulls are triggered
by a web hook from Our Own Kallithea every time it receives new commits. Usually merging
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 the new translations is a straightforward process consisting of a pull from the Weblate-hosted
repository which is available under the Data Exports tab in the Weblate interface.
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 Weblate tries to minimise the number of commits, but that doesn't always work, especially
Andrew Shadura
docs: update the translation howto...
r4959 when two translators work with different languages at more or less the same time.
It makes sense sometimes to re-order or fold commits by the same author when they touch
just the same language translation. That, however, may confuse Weblate sometimes, in
which case it should be manually convinced it has to discard the commits it created by
using its administrative interface.
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
docs: consistent spacing around headings...
r5433
Thomas De Schampheleire
i18n/how_to: fix typos
r7769 Regenerating translations after source code changes (admin-only)
----------------------------------------------------------------
Thomas De Schampheleire
i18n: how_to: add instructions to regenerate translations...
r7486
When the Kallithea source code changes, both the location as the content of
translation strings can change. It is therefore necessary to regularly
regenerate the `kallithea.pot` file containing these strings, as well as aligning
the translation files (`*.po`).
First update the translation strings::
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py extract_messages
Thomas De Schampheleire
i18n: how_to: add instructions to regenerate translations...
r7486
Mads Kiilerich
py3: officially support Python 3...
r8089 Then regenerate the translation files. This could either be done with `python3
Thomas De Schampheleire
i18n: how_to: add instructions to regenerate translations...
r7486 setup.py update_catalog` or with `msgmerge` from the `gettext` package. As
Weblate is also touching these translation files, it is preferred to use the
same tools (`msgmerge`) and settings as Weblate to minimize the diff::
find kallithea/i18n -name kallithea.po | xargs -I '{}' \
msgmerge --width=76 --backup=none --previous --update '{}' \
kallithea/i18n/kallithea.pot
Andrew Shadura
docs: update the translation howto...
r4959 Manual creation of a new language translation
---------------------------------------------
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 In the prepared development environment, run the following to ensure
all translation strings are extracted and up-to-date::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py extract_messages
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Create new language by executing following command::
Andrew Shadura
docs: update the translation howto...
r4959
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py init_catalog -l <new_language_code>
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 This creates a new translation under directory `kallithea/i18n/<new_language_code>`
based on the translation template file, `kallithea/i18n/kallithea.pot`.
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Edit the new PO file located in `LC_MESSAGES` directory with poedit or your
favorite PO files editor. After you finished with the translations, check the
translation file for errors by executing::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
msgfmt -f -c kallithea/i18n/<new_language_code>/LC_MESSAGES/<updated_file.po>
Andrew Shadura
docs: update the translation howto...
r4959 Finally, compile the translations::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py compile_catalog -l <new_language_code>
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
docs: consistent spacing around headings...
r5433
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 Manually updating translations
------------------------------
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Extract the latest versions of strings for translation by running::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py extract_messages
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Andrew Shadura
docs: update the translation howto...
r4959 Update the PO file by doing::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
py3: officially support Python 3...
r8089 python3 setup.py update_catalog -l <new_language_code>
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Thomas De Schampheleire
i18n: how_to: fix some non-fluent English...
r7485 Edit the newly updated translation file. Repeat all steps after the
`init_catalog` step from the 'new translation' instructions above.
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
docs: consistent spacing around headings...
r5433
Andrew Shadura
docs: update the translation howto...
r4959 Testing translations
--------------------
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Mads Kiilerich
docs: update i18n doc after TG migration changed lang to i18n.lang and test.ini is generated...
r7311 Edit `kallithea/tests/conftest.py` and set `i18n.lang` to `<new_language_code>`
and run Kallithea tests by executing::
Bradley M. Kuhn
Second step in two-part process to rename directories....
r4187
Thomas De Schampheleire
pytest migration: update documentation...
r5681 py.test
Mads Kiilerich
docs: fix some sphinx warnings...
r6716
.. _Weblate: http://weblate.org/