Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMove indexsidebar.html and switchers.js to docsbuild-scripts #90
Comments
|
I like this idea a lot. I'm not sure what you are suggesting replacing the index sidebar with stable -> https://docs.python.org/ |
|
It's in production now. Still to do:
|
The idea is that the cpython Doc/ repository should just care about building the documentation, not linking to other builds and languages from docs.python.org.
Building multiple versions, multiple languages, and linking them together is the role of docsbuild-scripts.
This would also avoid the need to update
switchers.jsandindexsidebar.htmlon every cpython branch for every new cpython release and every new language.What would need to change:
switchers=1fromcpython/Doc/Makefileif switchersblock incpython/tools/templates/layout.html. it already has an alternative. Add anidto the<li>so it can be easily found by the newswitchers.jsas the placeholders are dropped.switchers.jsto docsbuild-scripts and make it use the<li>new id instead of placeholders if they are not found, and maybe fallback to find the place from other ways so it can work on old branches without commiting to them.We then need a clean way for docsbuild-scripts to edit the HTML to make it load switchers.js.