Skip to content

Commit 8fcd1b5

Browse files
committed
Apply changes from review
1 parent 28b1f7c commit 8fcd1b5

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

Doc/howto/argparse.rst

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -788,14 +788,13 @@ but not both at the same time:
788788
-q, --quiet
789789
790790
791-
Internationalization support
792-
============================
791+
How to translate the argparse output
792+
====================================
793793

794794
The output of the :mod:`argparse` module such as its help text and error
795795
messages are all made translatable using the :mod:`gettext` module. This
796796
allows applications to easily localize messages produced by
797-
:mod:`argparse`. (If you are not familiar with Internationalization and
798-
Localization, you can check out :ref:`i18n-howto`).
797+
:mod:`argparse`. See also :ref:`i18n-howto`.
799798

800799
For instance, in this :mod:`argparse` output:
801800

@@ -818,9 +817,9 @@ For instance, in this :mod:`argparse` output:
818817
The strings ``usage:``, ``positional arguments:``, ``options:`` and
819818
``show this help message and exit`` are all translatable.
820819

821-
In order to translate these strings, you will probably want to extract them
820+
In order to translate these strings, they must first be extracted
822821
into a ``.po`` file. For example, using `Babel <https://babel.pocoo.org/>`__,
823-
you can run:
822+
run this command:
824823

825824
.. code-block:: shell-session
826825
@@ -831,7 +830,7 @@ module and output them into a file named ``messages.po``. This command assumes
831830
that your Python installation is in ``/usr/lib``.
832831

833832
You can find out the location of the :mod:`argparse` module on your system
834-
using this simple script::
833+
using this script::
835834

836835
import argparse
837836
print(argparse.__file__)

0 commit comments

Comments
 (0)