April 12, 2023, 7:14am
As we can see, there is a drop-down menu in the navigation bar of CMake Documentation so that we can toggle different versions:
However, there isn’t such a thing by default after we build the html from the Help directory.
I wondered how this thing is created automatically? Is there any script file like
April 13, 2023, 4:40pm
I’ve no idea how that’s handled. It’s done only for the official hosted docs, you don’t get it if building locally or in CI. Might have to wait for Brad to provide further info, unless
@ben.boeckel happens to know.
April 19, 2023, 4:23am
So…May I know who is the CMake team member responsible for publishing the CMake Documentation?
April 21, 2023, 1:26pm
I thinks this topic is related to this comment by
We configure sphinx with a custom template directory
here. That directory contains a custom layout template, which has special version switch code activated by passing -A versionswitch=1 when running sphinx. The version switch code loads version_switch.js, which we publish on the web host here.
The addition of the “This documents an old version of” and “Click here to see the latest release” is done by internal infrastructure we use to prepare the documentation for publication on cmake.org. B…