给定文件夹结构
docs # Source folder for sphinx doumentation
chapter # One of the chapters
section.rst # One of the sections
...
figures # Collection of figures
figure.fig # One of the figures
...
make.bat # The root folder from which one compiles their documentation
...
在section.rst
内,我尝试使用相对路径导入figure.fig
,如下所示
.. figure :: ../figures/figure.fig
The caption for the figure
我收到错误
E:\..\docs\chapter\section.rst:XX: WARNING: image file not readable: chapter\../figures/figure.fig
很明显,Sphinx没有解决相对路径。我很想知道是否有一项不涉及重组项目的工作。