mirror of
https://github.com/elastic/eland.git
synced 2025-07-11 00:02:14 +08:00
More readthedocs fixes. (#107)
* Minor fixes for readthedocs compatibility. * Adding doc templates
This commit is contained in:
parent
1d273ae465
commit
1c772d0e50
10
docs/_templates/api_redirect.html
vendored
Normal file
10
docs/_templates/api_redirect.html
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
{% set redirect = redirects[pagename.split("/")[-1]] %}
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Refresh" content="0; url={{ redirect }}.html" />
|
||||
<title>This API page has moved</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>This API page has moved <a href="{{ redirect }}.html">here</a>.</p>
|
||||
</body>
|
||||
</html>
|
6
docs/_templates/autosummary/accessor.rst
vendored
Normal file
6
docs/_templates/autosummary/accessor.rst
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
{{ fullname }}
|
||||
{{ underline }}
|
||||
|
||||
.. currentmodule:: {{ module.split('.')[0] }}
|
||||
|
||||
.. autoaccessor:: {{ (module.split('.')[1:] + [objname]) | join('.') }}
|
6
docs/_templates/autosummary/accessor_attribute.rst
vendored
Normal file
6
docs/_templates/autosummary/accessor_attribute.rst
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
{{ fullname }}
|
||||
{{ underline }}
|
||||
|
||||
.. currentmodule:: {{ module.split('.')[0] }}
|
||||
|
||||
.. autoaccessorattribute:: {{ (module.split('.')[1:] + [objname]) | join('.') }}
|
6
docs/_templates/autosummary/accessor_callable.rst
vendored
Normal file
6
docs/_templates/autosummary/accessor_callable.rst
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
{{ fullname }}
|
||||
{{ underline }}
|
||||
|
||||
.. currentmodule:: {{ module.split('.')[0] }}
|
||||
|
||||
.. autoaccessorcallable:: {{ (module.split('.')[1:] + [objname]) | join('.') }}.__call__
|
6
docs/_templates/autosummary/accessor_method.rst
vendored
Normal file
6
docs/_templates/autosummary/accessor_method.rst
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
{{ fullname }}
|
||||
{{ underline }}
|
||||
|
||||
.. currentmodule:: {{ module.split('.')[0] }}
|
||||
|
||||
.. autoaccessormethod:: {{ (module.split('.')[1:] + [objname]) | join('.') }}
|
33
docs/_templates/autosummary/class.rst
vendored
Normal file
33
docs/_templates/autosummary/class.rst
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
{% extends "!autosummary/class.rst" %}
|
||||
|
||||
{% block methods %}
|
||||
{% if methods %}
|
||||
|
||||
..
|
||||
HACK -- the point here is that we don't want this to appear in the output, but the autosummary should still generate the pages.
|
||||
.. autosummary::
|
||||
:toctree:
|
||||
{% for item in all_methods %}
|
||||
{%- if not item.startswith('_') or item in ['__call__'] %}
|
||||
{{ name }}.{{ item }}
|
||||
{%- endif -%}
|
||||
{%- endfor %}
|
||||
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% block attributes %}
|
||||
{% if attributes %}
|
||||
|
||||
..
|
||||
HACK -- the point here is that we don't want this to appear in the output, but the autosummary should still generate the pages.
|
||||
.. autosummary::
|
||||
:toctree:
|
||||
{% for item in all_attributes %}
|
||||
{%- if not item.startswith('_') %}
|
||||
{{ name }}.{{ item }}
|
||||
{%- endif -%}
|
||||
{%- endfor %}
|
||||
|
||||
{% endif %}
|
||||
{% endblock %}
|
6
docs/_templates/autosummary/class_without_autosummary.rst
vendored
Normal file
6
docs/_templates/autosummary/class_without_autosummary.rst
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
{{ fullname }}
|
||||
{{ underline }}
|
||||
|
||||
.. currentmodule:: {{ module }}
|
||||
|
||||
.. autoclass:: {{ objname }}
|
Loading…
x
Reference in New Issue
Block a user