Repository navigation
Configure the GitHub link in yardang's own docs - #166
Merged
Merged
Conversation
fuma reads the repository link from html_theme_options.github_url, which renders the GitHub icon in the sidebar footer and derives the edit-page link. The theme docs pointed at a [tool.yardang.sphinx] namespace that yardang never read, so correct the examples to [tool.yardang.html_theme_options]. Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com>
Contributor
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #166 +/- ##
=======================================
Coverage 89.02% 89.02%
=======================================
Files 16 16
Lines 2096 2096
Branches 214 214
=======================================
Hits 1866 1866
Misses 160 160
Partials 70 70 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
fuma reads the repository link from
html_theme_options, which renders the GitHub icon in the sidebar footer and derives the "Edit this page" link. yardang's own docs never set it, so after the switch to fuma the link disappeared. Addgithub_urlto[tool.yardang]inpyproject.toml.While wiring this up I found the theme docs point at a
[tool.yardang.sphinx]namespace that yardang never reads — theme options are taken from[tool.yardang]directly, as the "Sphinx Options" section already documents. Corrected the four examples, and removed a sentence claimingsearchlite_index_filenamepasses through the same nonextant namespace.Note that
github_urlis fuma-specific, soyardang previewbuilds for the other themes logunsupported theme option 'github_url'. The build still succeeds; the option belongs to fuma and the main site build uses it.Type of Change
Checklist
make lint)make test)No test covers this: it is repo configuration plus docs. Verified by generating the config (
html_theme_options = {'github_url': 'https://github.com/python-project-templates/yardang'}) and by building a sample project, which emits the link andaria-label="GitHub"in the rendered HTML. Suite: 118 of 119 pass;test_all.py::test_clifails locally because the optionalsphinxcontrib_rustextra is not installed, which is unrelated.