sphinx-contrib / sphinxcontrib-versioning

Sphinx extension that allows building versioned docs for self-hosting.
https://sphinxcontrib-versioning.readthedocs.io/en/latest/
MIT License
127 stars 80 forks source link

Usage with breathe? #44

Open mgiaco opened 7 years ago

mgiaco commented 7 years ago

Hello,

I use sphinx in combination with https://github.com/michaeljones/breathe. So the build works now but my problem is that breath use the xml output from doxygen also in the sphinx html output. When I run your extension i also updated my sphinx build in a way that doxygen is builded before. But the problem is that the xml folder is not gathered by the sphinxcontrib-versioning. Can I set a path which should also be copied or so? So it is like a static folder but is also generated on the fly.

mgiaco commented 7 years ago

So now i found out that the path is the problem. When I build my project with this extension I generate the doxygen output on a relative path. But the extension build the sphinx on a special path User/local/Temp/..... And then the doxygen xml output is never found by the sphinx/breathe build. How can I get that path where the build happens? os.getcwd() did not work because the running path is the project path but the extension does some special path switching. Why does the extension do not build in the project tree?

The only workaround I think is committing the doxygen xml output but that isn't really nice I think.

plauche commented 6 years ago

@Robpol86 any suggestions on how to work around this? I've run into the same issue. I looked at moving my doxygen generation into the conf.py but it looks like that is executed prior to sphinx-versioning creating a temp dir and moving there.