-
-
Notifications
You must be signed in to change notification settings - Fork 126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use sphinx-multiversion to support documentation for multiple versions #349
Conversation
Tagging @OriolAbril, who might be interested |
Codecov Report
@@ Coverage Diff @@
## master #349 +/- ##
=======================================
Coverage 90.28% 90.28%
=======================================
Files 13 13
Lines 1348 1348
=======================================
Hits 1217 1217
Misses 131 131 Continue to review full report at Codecov.
|
Does this rebuild all the documentation for all versions every time docs are built? I am not sure I understand how it works so that old versions show the links to newer versions, |
Yes, unfortunately, it rebuilds all docs for all versions every time you build it. I still don't know if it is possible to only build what has been modified. And yes, I think EDIT: I haven't read in detail but this problem is discussed here. |
It is provided you have some cool javascript that generates the version menu dinamically from a json file (shared between all versions). IIUC, this is what readthedocs and documenter do. Documenter works seamlessly doing this with GitHub pages (see ArviZ.jl docs pages, respective html and source), but so far I have not seen anything close in python and I don't understand why but I also don't know enough of CI, javascript, html or any of the skills needed to actually do this |
There are two projects that use sphinx-multiversion without re-building everything from 0, here and here. But they use a version of the package that is not merged yet (this PR). I'm not sure if we should follow them and do the same here, having to keep an eye close to the development of sphinx-multiversion, or just keep using sphinx and add a GitHub action to automatically build the latest release documentation and upload to gh-pages. |
I'm merging to test if this works well... Hope not to break anything 🙏 |
I added sphinx-multiversion to support the creation of docs for each release. I have also created a jinja template to put the links for the different versions and also some information. The
gh-pages-redirect.html
refers to a wrong link, I'm going to fix it later.Illustrative gif