Skip to content

Commit 4e43bfa

Browse files
committed
Initial commit for api and submissions module docs.
1 parent 5e3da7f commit 4e43bfa

File tree

3 files changed

+46
-7
lines changed

3 files changed

+46
-7
lines changed

docs/source/api_index.rst

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
API
2+
===
3+
4+
.. toctree::
5+
:maxdepth: 2
6+
:caption: API
7+
8+
API
9+
---
10+
11+
.. automodule:: judge0.api
12+
:members:
13+
:undoc-members:
14+
15+
Submission
16+
----------
17+
18+
.. automodule:: judge0.submission
19+
:members:
20+
:undoc-members:

docs/source/conf.py

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@
66
# -- Project information -----------------------------------------------------
77
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
88

9+
10+
import os
11+
import sys
12+
913
project = "Judge0 Python SDK"
1014
copyright = "2024, Judge0"
1115
author = "Judge0"
@@ -14,7 +18,7 @@
1418
# -- General configuration ---------------------------------------------------
1519
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
1620

17-
extensions = ["sphinx_rtd_theme"]
21+
extensions = ["sphinx.ext.autodoc"]
1822

1923
templates_path = ["_templates"]
2024
exclude_patterns = []
@@ -25,3 +29,22 @@
2529

2630
html_theme = "sphinx_rtd_theme"
2731
html_static_path = ["_static"]
32+
33+
sys.path.insert(0, os.path.abspath("../src/judge0")) # Adjust as needed
34+
35+
html_theme_options = {
36+
# Toc options
37+
"collapse_navigation": True,
38+
"sticky_navigation": True,
39+
"navigation_depth": 4,
40+
"includehidden": True,
41+
"titles_only": False,
42+
}
43+
44+
autodoc_default_options = {
45+
"members": True,
46+
"undoc-members": True,
47+
"private-members": False,
48+
"special-members": False,
49+
"inherited-members": False,
50+
}

docs/source/index.rst

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,8 @@
66
Judge0 Python SDK documentation
77
===============================
88

9-
Add your content using ``reStructuredText`` syntax. See the
10-
`reStructuredText <https://www.sphinx-doc.org/en/master/usage/restructuredtext/index.html>`_
11-
documentation for details.
12-
13-
149
.. toctree::
1510
:maxdepth: 2
16-
:caption: Contents:
11+
:caption: Contents
1712

13+
api_index

0 commit comments

Comments
 (0)