Skip to content

Commit 0d9c747

Browse files
committed
update doc gen
1 parent d0bb3fb commit 0d9c747

File tree

3 files changed

+28
-27
lines changed

3 files changed

+28
-27
lines changed

.github/workflows/deploy_mkdocs.yml

-22
Original file line numberDiff line numberDiff line change
@@ -30,27 +30,5 @@ jobs:
3030
python -m pip install --upgrade pip
3131
python -m pip install -e .["docs"]
3232
33-
- name: Create API docs
34-
env:
35-
# we need to set a fake PG url or import will fail
36-
DATABASE_URL: postgresql://username:[email protected]:5439/postgis
37-
run: |
38-
pdocs as_markdown \
39-
--output_dir docs/src/api \
40-
--exclude_source \
41-
--overwrite \
42-
tipg.filter.evaluate \
43-
tipg.filter.filters \
44-
tipg.resources.enums \
45-
tipg.resources.response \
46-
tipg.collections \
47-
tipg.database \
48-
tipg.dependencies \
49-
tipg.errors \
50-
tipg.factory \
51-
tipg.middleware \
52-
tipg.model \
53-
tipg.settings
54-
5533
- name: Deploy docs
5634
run: mkdocs gh-deploy --force -f docs/mkdocs.yml

docs/mkdocs.yml

+24-2
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ nav:
2828
- "TiPg Vector Tiles server": advanced/ogc_tiles_server.md
2929
- "TiPg Features server": advanced/ogc_features_server.md
3030
- API:
31-
- db: api/tipg/db.md
32-
- dbmodel: api/tipg/dbmodel.md
31+
- database: api/tipg/database.md
3332
- dependencies: api/tipg/dependencies.md
3433
- errors: api/tipg/errors.md
3534
- factory: api/tipg/factory.md
@@ -48,6 +47,29 @@ nav:
4847

4948
plugins:
5049
- search
50+
- mkdocstrings:
51+
enable_inventory: true
52+
handlers:
53+
python:
54+
paths: [src]
55+
options:
56+
filters:
57+
- "!^__post_init__"
58+
docstring_section_style: list
59+
docstring_style: google
60+
line_length: 100
61+
separate_signature: true
62+
show_root_heading: true
63+
show_signature_annotations: true
64+
show_source: false
65+
show_symbol_type_toc: true
66+
signature_crossrefs: true
67+
extensions:
68+
- griffe_inherited_docstrings
69+
import:
70+
- https://docs.python.org/3/objects.inv
71+
- https://docs.pydantic.dev/latest/objects.inv
72+
- https://fastapi.tiangolo.com/objects.inv
5173

5274
theme:
5375
name: material

pyproject.toml

+4-3
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,11 @@ server = [
5656
"uvicorn[standard]>=0.12.0,<0.19.0",
5757
]
5858
docs = [
59+
"black>=23.10.1",
5960
"mkdocs",
60-
"mkdocs-material",
61-
"pygments",
62-
"pdocs",
61+
"mkdocs-material[imaging]>=9.5",
62+
"griffe-inherited-docstrings>=1.0.0",
63+
"mkdocstrings[python]>=0.25.1",
6364
]
6465

6566
[project.urls]

0 commit comments

Comments
 (0)