【发布时间】:2021-02-16 15:34:42
【问题描述】:
我正在使用read the docs 主题来使用 sphinx 创建 HTML 内容。在主题中,我想编辑“在 Github 上编辑”部分的超链接。我可以使用 conf.py 文件中的以下变量启用或禁用链接。
html_context = {
'display_github': True,
'github_repo': 'xyz',
}`
这导致以下链接https://github.com/xyz
-
但是,我们公司有一个内部 GitLab 存储库,我想将链接更改为 https://github.companyname.com/xyz
-
另外,主题中是否有一个变量来指定分支名称?
【问题讨论】:
-
欢迎来到 Stack Overflow。如果答案解决了您的问题,您应该在答案左侧accept it by clicking the green check mark。请参阅this meta thread 中的完整说明。
标签: html python-sphinx read-the-docs