Skip to content
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

Update Sphinx version and migrate to sphinx-multiversion CLEWS-33782 #292

Merged
merged 8 commits into from
Dec 3, 2020

Conversation

jli
Copy link
Contributor

@jli jli commented Dec 2, 2020

This upgrades Sphinx from 1.5.6 (from 2017-05) to 3.1.2 (2020-07), and migrates from sphinxcontrib-versioning (SCV) to sphinx-multiversion (SMV). These extensions both enable building multiple versions of our docs. SCV hasn't been updated since 2016, and doesn't work with more recent versions of Sphinx (see sphinx-contrib/sphinxcontrib-versioning#78 and sphinx-contrib/sphinxcontrib-versioning#69). More recent versions of Sphinx are needed so that we can use nbsphinx in #282.

The main complexity here is from the new script sphinx_push_ghpages.sh, which replicates functionality that SCV have which was missing from SMV. I've tested this quite a bit and I'm pretty confident that it's working correctly, including when called from Shippable.

john li added 7 commits December 1, 2020 19:07
- upgrades Sphinx from 1.5.6 (from 2017-05) to 3.1.2 (2020-07)
- switch to sphinx-multiversion from sphinxcontrib-versioning

Relevant changes in Sphinx are mostly a bunch of bugfixes and improved
HTML output: https://www.sphinx-doc.org/en/master/changes.html
Some of the HTML output got a little fancier, but not that noticable.

(Sphinx 3.1.2 is chosen because Sphinx 3.2.0 adds local link checking,
which doesn't quite work right with our docs. Also see
#291)
instead of hiding the branch version selectors with CSS, we just don't
include them via the versions template. improvement from the previous
sphinxcontrib-versioning setup: now, the development branch docs are
included in the selector alongside the version tags.
replicating another sphinxcontrib-versioning feature in
sphinx-multiversion. functionality is identical.
The old sphinxcontrib-versioning extension has a handy 'push' command to
build and push new documentation to a git branch. The
sphinx-multiversion extension we're transitioning to doesn't have this,
so we replicate it with a shell script.
i'm not sure why the ssh-agent/ssh-add /tmp/ssh/00_sub bit was added in
the first place, but it shouldn't be necessary, as this identity should
be added automatically: http://docs.shippable.com/ci/ssh-keys/

tested manually and shippable still seems to be able to push to gh-pages
without it.
For some reason, when running on shippable, the '\t' escape pattern for
matching tabs with grep doesn't work. So, we just drop the tab from the
pattern since it's not that important.
@muzigao muzigao merged commit 0f1d225 into development Dec 3, 2020
@muzigao muzigao deleted the jli-updatesphinx branch December 3, 2020 14:25
muzigao added a commit that referenced this pull request Nov 12, 2021
Update Sphinx version and migrate to sphinx-multiversion CLEWS-33782
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants