Swapping source and destination language

11 views
Skip to first unread message

Denis Cardon

unread,
Jan 6, 2020, 1:44:11 PM1/6/20
to sphinx-users
Hi everyone,

First, thanks again for this very nice piece of software. Sphinx really
helps to write documentation and motivate people to write it :-) And of
course happy new year 2020!

I need to swap a source language (French) with translation (English), so
that official doc is in English and translation is in French. Po files
are all uptodate.

I have done that in the past with some hackish scripts parsing the html
output to recreate the rst source, and fixing leftover stuff by hand. I
have already tried to get some feed back in the past to no avail.

However I'm pretty sure there is a better way to do using the AST of
docutil, but I have not found good example on how to bootstrap the
thing. I have been also playing with pandoc but I couldn't get anything
satisfying.

If you could give me some hint on how to do that in a proper way, I'd be
very grateful :-) (either with pandoc or docutil).

Cheers,

Denis


--
Denis Cardon
Tranquil IT
12 avenue Jules Verne (Bat. A)
44230 Saint Sébastien sur Loire (FRANCE)
tel : +33 (0) 240 975 755
http://www.tranquil.it

Tranquil IT recrute! https://www.tranquil.it/nous-rejoindre/
Samba install wiki for Frenchies : https://dev.tranquil.it
WAPT, software deployment made easy : https://wapt.fr

Komiya Takeshi

unread,
Jan 7, 2020, 11:16:32 AM1/7/20
to sphinx...@googlegroups.com
Hi Denis,

FWIW, I found `sphinx-rst-builder` extension. It might help your case.
https://pypi.org/project/sphinx-rst-builder/

Thanks,
Takeshi KOMIYA

2020年1月7日(火) 3:44 Denis Cardon <dca...@tranquil.it>:
> --
> You received this message because you are subscribed to the Google Groups "sphinx-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sphinx-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sphinx-users/da1920c8-c6bb-ec8a-084b-fd492e79b5e5%40tranquil.it.

Denis Cardon

unread,
Jan 7, 2020, 12:47:38 PM1/7/20
to sphinx...@googlegroups.com
Hi Takeshi,

Le 01/07/2020 à 05:16 PM, Komiya Takeshi a écrit :
> Hi Denis,
>
> FWIW, I found `sphinx-rst-builder` extension. It might help your case.
> https://pypi.org/project/sphinx-rst-builder/

thanks a lot! It is loosing a few sphinx specific stuff like code block
type, :abbr:, meta and does expands toctrees, but it is already a very
good start!

Thanks,

Denis
Reply all
Reply to author
Forward
0 new messages