@@ -6,23 +6,29 @@ run these commands in the root directory of searx
66Add new language
77~~~~~~~~~~~~~~~~
88
9−``pybabel init -i messages.pot -d searx/translations -l it``
9+.. code:: shell
10+
11+ pybabel init -i messages.pot -d searx/translations -l it
1012
1113Update .po files
1214~~~~~~~~~~~~~~~~
1315
14−``./utils/update-translations.sh``
16+.. code:: shell
17+
18+ ./utils/update-translations.sh
1519
1620You may have errors here. In that case, edit the
1721``update-translations.sh`` script to change ``pybabel`` to
18−``pybabel-python2``
22+``pybabel-python2`` or ``pybabel2``
1923
2024After this step, you can modify the .po files.
2125
2226Compile translations
2327~~~~~~~~~~~~~~~~~~~~
2428
25−``pybabel compile -d searx/translations``
29+.. code:: shell
30+
31+ pybabel compile -d searx/translations
2632
2733Transifex stuff
2834~~~~~~~~~~~~~~~
@@ -32,12 +38,14 @@ Init Project
3238
3339.. code:: shell
3440
41+ tx init # Transifex instance: https://www.transifex.com/asciimoo/searx/
42+
3543 tx set --auto-local -r searx.messagespo 'searx/translations/<lang>/LC_MESSAGES/messages.po' \
3644 --source-lang en --type PO --source-file messages.pot --execute
3745
38−http://docs.transifex.com/developer/client/set
46+http://docs.transifex.com/client/init/
3947
40−*TODO: mapping between transifex and searx*
48+http://docs.transifex.com/client/set/
4149
4250Get translations
4351^^^^^^^^^^^^^^^^
@@ -46,29 +54,27 @@ Get translations
4654
4755 tx pull -a
4856
49−http://docs.transifex.com/developer/client/pull
57+http://docs.transifex.com/client/pull
5058
5159Upload source File
5260^^^^^^^^^^^^^^^^^^
5361
54−::
62+.. code:: shell
5563
5664 tx push -s
5765
5866Upload all Translation
5967^^^^^^^^^^^^^^^^^^^^^^
6068
61−::
69+.. code:: shell
6270
6371 tx push -s -t
6472
65−upload specifc Translation (only for admins)
66−~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
73+upload specifc Translation
74+~~~~~~~~~~~~~~~~~~~~~~~~~~
6775
68−::
76+.. code:: shell
6977
7078 tx push -t -l tr
7179
72−http://docs.transifex.com/developer/client/push
73−
74−*TODO: upload empty files? (new translations)*
80+http://docs.transifex.com/client/push