【发布时间】:2019-10-13 15:06:41
【问题描述】:
我按照阅读文档的说明进行操作,但出现此错误:
bash Sphinx 错误:主文件 /home/docs/checkouts/readthedocs.org/user_builds/mybinders/checkouts/latest/docs/source/contents.rst 没找到
您需要阅读 docs yaml 文件吗?
【问题讨论】:
标签: read-the-docs
我按照阅读文档的说明进行操作,但出现此错误:
bash Sphinx 错误:主文件 /home/docs/checkouts/readthedocs.org/user_builds/mybinders/checkouts/latest/docs/source/contents.rst 没找到
您需要阅读 docs yaml 文件吗?
【问题讨论】:
标签: read-the-docs
我需要我的conf.py,因为我正在使用扩展,所以只需添加
master_doc = 'contents'
发给你的conf.py,然后
将您的 index.rst 重命名为 contents.rst。
在构建通过之后,您仍然不会在 ReadTheDocs 上看到任何内容,除了“此页面仍然不存在”,只需转到:
https://your-project.readthedocs.io/en/latest/contents.html
你会在那里看到你的文档。
【讨论】:
如果您有自己的conf.py 文件,它会覆盖读取文档的默认conf.py。默认情况下,Sphinx 期望主文档为contents。阅读文档会将主文档设置为index(或您在设置中指定的任何内容)。尝试将此添加到您的conf.py:
master_doc = 'index'
欲了解更多信息,请查看此问题:https://github.com/rtfd/readthedocs.org/issues/2569
【讨论】: