Skip to content

Commit 9d135a5

Browse files
committed
Use sphinx-autosummary to build api doc
1 parent 57f7e3e commit 9d135a5

26 files changed

+155
-335
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{{ fullname | escape | underline}}
2+
3+
.. currentmodule:: {{ module }}
4+
5+
.. autoclass:: {{ objname }}
6+
:members:
7+
:undoc-members:
8+
:show-inheritance:
9+
10+
{% block methods %}
11+
{% if methods %}
12+
.. rubric:: {{ _('Methods') }}
13+
14+
.. autosummary::
15+
:nosignatures:
16+
{% for item in methods %}
17+
{%- if not item.startswith('_') %}
18+
~{{ name }}.{{ item }}
19+
{%- endif -%}
20+
{%- endfor %}
21+
{% endif %}
22+
{% endblock %}
23+
24+
{% block attributes %}
25+
{% if attributes %}
26+
.. rubric:: {{ _('Attributes') }}
27+
28+
.. autosummary::
29+
{% for item in attributes %}
30+
~{{ name }}.{{ item }}
31+
{%- endfor %}
32+
{% endif %}
33+
{% endblock %}
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
{{ fullname | escape | underline}}
2+
3+
.. automodule:: {{ fullname }}
4+
5+
{% block attributes %}
6+
{% if attributes %}
7+
.. rubric:: Module attributes
8+
9+
.. autosummary::
10+
:toctree:
11+
{% for item in attributes %}
12+
{{ item }}
13+
{%- endfor %}
14+
{% endif %}
15+
{% endblock %}
16+
17+
{% block functions %}
18+
{% if functions %}
19+
.. rubric:: {{ _('Functions') }}
20+
21+
.. autosummary::
22+
:toctree:
23+
:nosignatures:
24+
{% for item in functions %}
25+
{{ item }}
26+
{%- endfor %}
27+
{% endif %}
28+
{% endblock %}
29+
30+
{% block classes %}
31+
{% if classes %}
32+
.. rubric:: {{ _('Classes') }}
33+
34+
.. autosummary::
35+
:toctree:
36+
:template: custom-class-template.rst
37+
:nosignatures:
38+
{% for item in classes %}
39+
{{ item }}
40+
{%- endfor %}
41+
{% endif %}
42+
{% endblock %}
43+
44+
{% block exceptions %}
45+
{% if exceptions %}
46+
.. rubric:: {{ _('Exceptions') }}
47+
48+
.. autosummary::
49+
:toctree:
50+
{% for item in exceptions %}
51+
{{ item }}
52+
{%- endfor %}
53+
{% endif %}
54+
{% endblock %}
55+
56+
{% block modules %}
57+
{% if modules %}
58+
.. autosummary::
59+
:toctree:
60+
:template: custom-module-template.rst
61+
:recursive:
62+
{% for item in modules %}
63+
{{ item }}
64+
{%- endfor %}
65+
{% endif %}
66+
{% endblock %}

doc/api.rst

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
===
2+
API
3+
===
4+
5+
6+
.. autosummary::
7+
:toctree: _autosummary
8+
:template: custom-module-template.rst
9+
:recursive:
10+
11+
py_eddy_tracker.appli
12+
py_eddy_tracker.dataset.grid
13+
py_eddy_tracker.featured_tracking
14+
py_eddy_tracker.observations.network
15+
py_eddy_tracker.observations.observation
16+
py_eddy_tracker.observations.tracking
17+
py_eddy_tracker.eddy_feature
18+
py_eddy_tracker.generic
19+
py_eddy_tracker.gui
20+
py_eddy_tracker.poly
21+
py_eddy_tracker.tracking

doc/autodoc/eddy_feature.rst

Lines changed: 0 additions & 8 deletions
This file was deleted.

doc/autodoc/featured_tracking.rst

Lines changed: 0 additions & 7 deletions
This file was deleted.

doc/autodoc/generic.rst

Lines changed: 0 additions & 7 deletions
This file was deleted.

doc/autodoc/grid.rst

Lines changed: 0 additions & 8 deletions
This file was deleted.

doc/autodoc/observations.rst

Lines changed: 0 additions & 13 deletions
This file was deleted.

doc/autodoc/poly.rst

Lines changed: 0 additions & 8 deletions
This file was deleted.

doc/autodoc/tracking.rst

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)