Skip to content

Commit

Permalink
Add poedit as a tool in the README (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
eduardogmisiuk committed Sep 22, 2020
1 parent 4486806 commit da42a0c
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,19 +64,33 @@ make html BUILDDIR=build/html-pt_BR O='-d build/doctrees/ -D language=pt_BR'

To update the documentation, follow the steps below:

1. Update the source files for the english version
2. Extract translatable messages from the english version
1. Update the source files for the english version.
2. Extract translatable messages from the english version:

```shell
make gettext
```

3. Update the message catalog (PO Files) for pt_BR language
3. Update the message catalog (PO Files) for pt_BR language:

```shell
sphinx-intl -c source/conf.py update -p build/gettext -l pt_BR
```

4. Translate the messages in the pt_BR language PO files
4. Translate the messages in the pt_BR `.po` files. You don't need to deal with these files directly
in your text editor, check the next section for more details.

This workflow is based on the [internationalization feature of Sphinx](http://www.sphinx-doc.org/en/stable/intl.html).

## Useful tools

`.po` files are kinda annoying to handle. Luckily, there are tools that can understand this format
and provide us a better interface to deal with them. Supposing you are using Ubuntu, you can install
`poedit`:

```shell
apt-get install poedit
```

After running it, you can add the catalog to see all your files in its interface in the
`Catalog Manager` under the `File` menu.

0 comments on commit da42a0c

Please sign in to comment.