docs: add Sphinx + Read the Docs infrastructure

- Add .readthedocs.yaml build config (Ubuntu 22.04, Python 3.11)
- Add docs/conf.py with myst-parser for Markdown support
- Add docs/index.md toctree including README and existing docs
- Add docs/readme.md to include root README via myst directive
- Add docs/requirements.txt for Sphinx build dependencies
- Add docs/_build/ to .gitignore
This commit is contained in:
Justin Gu
2026-06-08 03:36:40 +08:00
parent 6f7f5bac16
commit 9d906c340c
7 changed files with 73 additions and 4 deletions
+33
View File
@@ -0,0 +1,33 @@
# -- Sphinx configuration for easy-tdx ---------------------------------------
project = "easy-tdx"
copyright = "2025, Justin Gu"
author = "Justin Gu"
# The full version, including alpha/beta/rc tags
release = "1.7.1"
# -- Extensions ---------------------------------------------------------------
extensions = [
"myst_parser",
]
# -- MyST parser config -------------------------------------------------------
myst_enable_extensions = [
"colon_fence",
"deflist",
]
# Suppress cross-reference warnings for relative links (e.g. docs/*.md, LICENSE)
suppress_warnings = ["myst.xref_missing"]
# -- HTML output --------------------------------------------------------------
html_theme = "sphinx_rtd_theme"
html_theme_options = {
"navigation_depth": 3,
}
# -- Source suffix -------------------------------------------------------------
source_suffix = {
".rst": "restructuredtext",
".md": "markdown",
}
+12
View File
@@ -0,0 +1,12 @@
# easy-tdx 文档
```{toctree}
:maxdepth: 2
:caption: 目录
readme
api_reference
field_mapping
indicator-zhuoyao
indicator-bias-signal
```
+5
View File
@@ -0,0 +1,5 @@
# easy-tdx
```{include} ../README.md
:relative-images:
```
+4
View File
@@ -0,0 +1,4 @@
sphinx>=7.0
sphinx-autobuild>=2024.0
myst-parser>=3.0
sphinx-rtd-theme>=2.0