Translating Easily with Sphinx (Updating the Source Document)
When you write technical documentation, using sphinx is convenient. And if you are translating technical documentation, sphinx-intl is extremely useful. It has many advantages, but it also easily solves the problem that causes the most pain for technical documentation translators: the frequent changes to the source document. It pinpoints exactly which parts have changed and tells you. You just need to re-translate those parts!
Let’s get started.
This is based on translating into Korean. Of course, there is also a Korean translation of the official Sphinx documentation.
- Update the changes to the document
# Pull from the original repository of the document git pull master - Update the translation files
# Update (regenerate) the po file, which is Sphinx's translation file make gettext cd docs sphinx-intl update -p _build/locale -l ko - Check the updated parts
- Compare carefully with git diff and organize the updated documents
- Searching for
#, fuzzymakes it easy to find the changed parts of the source text!
- Check it in HTML
# Render the page translated into the ko language as HTML make -e SPHINXOPTS="-D language='ko'" html
The Hitchhiker’s Guide to Python! is being translated using the method above. It’s doomed
Leave a comment