Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/330.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ssis/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python Sphinx-包含文件中的相对链接 我正在使用狮身人面像来记录一个C++项目。我在src文件夹中有一个readme,还有一个完整的帮助网站,可以发布到使用生成的docs文件夹中。我想重用我的src文件夹中的readme。readme包含src文件夹中的代码(使用literalclude指令)_Python_Python Sphinx_Restructuredtext - Fatal编程技术网

Python Sphinx-包含文件中的相对链接 我正在使用狮身人面像来记录一个C++项目。我在src文件夹中有一个readme,还有一个完整的帮助网站,可以发布到使用生成的docs文件夹中。我想重用我的src文件夹中的readme。readme包含src文件夹中的代码(使用literalclude指令)

Python Sphinx-包含文件中的相对链接 我正在使用狮身人面像来记录一个C++项目。我在src文件夹中有一个readme,还有一个完整的帮助网站,可以发布到使用生成的docs文件夹中。我想重用我的src文件夹中的readme。readme包含src文件夹中的代码(使用literalclude指令),python,python-sphinx,restructuredtext,Python,Python Sphinx,Restructuredtext,该项目的结构如下: project src algo.cpp readme.rst CMakeLists.txt docs source index.rst conf.py code_link.rst build Makefile 按照本文中的建议,我能够将我的索引与我的自述文件链接,但是自述文件中代码文件的路径现在是相对于文档的路径。因此,自述文件不再依靠其自身的失败重用思想独立呈现 有没有办法在

该项目的结构如下:

project
  src
    algo.cpp
    readme.rst
    CMakeLists.txt
 docs
    source
       index.rst
       conf.py
       code_link.rst
    build
    Makefile
按照本文中的建议,我能够将我的
索引
与我的
自述文件
链接,但是
自述文件
中代码文件的路径现在是相对于
文档的路径。因此,
自述文件
不再依靠其自身的失败重用思想独立呈现


有没有办法在包含的文件中包含相对于包含的文件的链接?

正如您提到的readthedocs.org,我假设您的项目是开源的。你能提供一个到源代码的链接吗?正如你提到的readthedocs.org,我假设你的项目是开源的。你能提供一个到源代码的链接吗?