Skip to content

Commit fce9ccf

Browse files
datapythonistajreback
authored andcommitted
DOC: Fix building of a single API document (#24506)
1 parent c4ac0d6 commit fce9ccf

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

doc/make.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def __init__(self, num_jobs=0, include_api=True, single_doc=None,
5050
if single_doc and single_doc.endswith('.rst'):
5151
self.single_doc_html = os.path.splitext(single_doc)[0] + '.html'
5252
elif single_doc:
53-
self.single_doc_html = 'generated/pandas.{}.html'.format(
53+
self.single_doc_html = 'api/generated/pandas.{}.html'.format(
5454
single_doc)
5555

5656
def _process_single_doc(self, single_doc):

doc/source/conf.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,7 @@
9898
if (fname == 'index.rst'
9999
and os.path.abspath(dirname) == source_path):
100100
continue
101-
elif (pattern == '-api'
102-
and (fname == 'api.rst' or dirname == 'generated')):
101+
elif pattern == '-api' and dirname == 'api':
103102
exclude_patterns.append(fname)
104103
elif fname != pattern:
105104
exclude_patterns.append(fname)

doc/source/index.rst.template

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ See the package overview for more detail about what's in the library.
113113
{{ single_doc[:-4] }}
114114
{% elif single_doc %}
115115
.. autosummary::
116-
:toctree: generated/
116+
:toctree: api/generated/
117117

118118
{{ single_doc }}
119119
{% else -%}

0 commit comments

Comments
 (0)