Closed tomkralidis closed 10 years ago
This is now setup (thanks @rduivenvoorde for debugging) at https://www.transifex.com/projects/p/MetaSearch. Notes:
paver extract_messages
provides the bootstrap to get the initial strings for UI, UI templates and docsWorkflow:
tx push -s
)tx pull -a
paver compile_messages
builds all the .qm / .mo filespaver refresh_docs
builds all docs for all languagesdone. Process:
# upload to Transifex
paver extract_messages` # extract strings
tx push -s # send en sources to Transifex
# build
`tx pull -a` # pull all languages from Transifex
paver compile_messages
paver refresh_docs
This results in a fully translated package to work against, package and upload.
@rduivenvoorde: the last outstanding item is docs/website. paver refresh_docs
will build docs in all languages. paver publish_docs
(don't try it yet) will publish the English docs as current (to http://geopython.github.io/MetaSearch/), and the other languages get published to http://geopython.github.io/MetaSearch/<lang>
.
Is there another structure we should do to make things better? How does QGIS do it? As well, we need a way to provide language selection in the docs.
As well, foreach language, perhaps we can add the following steps to publish_docs
:
_static
, _sources
, _images
directories_static
, _sources
, _images
directoriesHi Tom, with the QGIS sites we use sphinx-intl (https://pypi.python.org/pypi/sphinx-intl)
we only keep resources(=images etc) separated per language, where 'en' is the base-one and other can be copied over it. Sources are only en, and translations are only available as po files in i18n/locale dir. Themes are also not localized (some right to left magic via separate css file).
So in the build dir we first copy all english images (from resources/en so we have an english 'base'), and then we overwrite them with (optionally) available localized images (with exact the same name in resources/xx).
see https://github.com/qgis/QGIS-Website/blob/master/Makefile#L87-L114
Done. Website updated with multilingual docs/setup.
Applied to both plugin and docs.