Skip to content

Commit 509f6b7

Browse files
committed
WIP Rework pulp-docs as a mkdocs plugin
1 parent 66d7e5e commit 509f6b7

File tree

288 files changed

+495
-127
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

288 files changed

+495
-127
lines changed

docs/rest_api.md

-15
This file was deleted.

docs/sections/help/more/governance/code-of-conduct.md

-75
This file was deleted.

mkdocs.yml

+162
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,162 @@
1+
site_name: Pulp Project
2+
site_url: https://pulpproject.org/
3+
repo_url: https://github.com/pulp/pulpcore
4+
repo_name: pulp/pulpcore
5+
6+
docs_dir: pulp_docs
7+
theme:
8+
name: material
9+
logo: assets/pulp_logo_icon.svg
10+
favicon: assets/favicon.ico
11+
features:
12+
- navigation.indexes
13+
- content.code.annotate
14+
- navigation.tabs
15+
- navigation.sections
16+
- navigation.path
17+
# - navigation.footer
18+
- navigation.top
19+
- toc.follow
20+
- search.suggest
21+
- search.highlight
22+
- content.code.annotation
23+
- content.code.copy
24+
- content.action.edit
25+
language: en
26+
palette:
27+
- media: "(prefers-color-scheme: light)"
28+
scheme: default
29+
primary: custom
30+
accent: black
31+
toggle:
32+
icon: material/toggle-switch-off-outline
33+
name: Switch to dark mode
34+
- media: "(prefers-color-scheme: dark)"
35+
scheme: slate
36+
toggle:
37+
icon: material/toggle-switch
38+
name: Switch to light mode
39+
# Blog's Navigation needs to be excempt from literate nav...
40+
nav:
41+
- Home: "index.md"
42+
- "User Manual":
43+
- "user/index.md"
44+
- "Developer Manual":
45+
- "dev/index.md"
46+
- Blog:
47+
- "blog/index.md"
48+
- Help: "help/"
49+
plugins:
50+
- PulpDocs:
51+
repositories:
52+
- title: "Pulpcore"
53+
path: "pulpcore"
54+
kind: "Core"
55+
rest_api: "core"
56+
- title: "Ansible"
57+
path: "pulp_ansible"
58+
kind: "Content"
59+
rest_api: "ansible"
60+
- title: "Debian"
61+
path: "pulp_deb"
62+
kind: "Content"
63+
rest_api: "deb"
64+
- title: "File"
65+
path: "pulpcore/pulp_file"
66+
kind: "Content"
67+
rest_api: "file"
68+
#TODO Fix cli code paths for docstrings
69+
- title: "Pulp CLI"
70+
path: "pulp-cli"
71+
kind: "Interaction"
72+
- title: "Pulp Glue"
73+
path: "pulp-cli/pulp-glue"
74+
kind: "Interaction"
75+
- title: "Pulp Docs"
76+
path: "pulp-docs"
77+
kind: "Other"
78+
- title: "Certguard"
79+
path: "pulpcore/pulp_certguard"
80+
kind: "Other"
81+
# rest_api: "certguard"
82+
- search
83+
- site-urls
84+
- blog:
85+
blog_dir: blog
86+
blog_toc: false
87+
- macros:
88+
render_by_default: false
89+
- tags:
90+
tags_file: pulp-docs/pulp_docs/tags.md
91+
- literate-nav:
92+
nav_file: _SUMMARY.md
93+
- mkdocstrings:
94+
handlers:
95+
python:
96+
options:
97+
show_source: false
98+
show_symbol_type_heading: true
99+
show_symbol_type_toc: true
100+
docstring_section_style: list # table, list, spacy
101+
filters: ["!^_"]
102+
heading_level: 2
103+
show_root_heading: true
104+
show_root_toc_entry: true
105+
show_if_no_docstring: false
106+
show_signature_annotations: true
107+
separate_signature: false
108+
members_order: "source"
109+
merge_init_into_class: true
110+
paths: []
111+
extra:
112+
social:
113+
- icon: "fontawesome/brands/github-alt"
114+
link: "https://github.com/pulp"
115+
- icon: "fontawesome/brands/discourse"
116+
link: "https://discourse.pulpproject.org/"
117+
- icon: "fontawesome/solid/comments"
118+
link: "https://matrix.to/#/!HWvLQmBGVPfJfTQBAu:matrix.org"
119+
analytics:
120+
provider: google
121+
property: G-8M0N5XEY4W
122+
123+
extra_css:
124+
- css/extra.css
125+
- css/mkdocstrings.css
126+
127+
markdown_extensions:
128+
# Python Markdown
129+
- abbr
130+
- admonition
131+
- attr_list
132+
- def_list
133+
- footnotes
134+
- md_in_html
135+
- toc:
136+
permalink: true
137+
- pymdownx.arithmatex:
138+
generic: true
139+
- pymdownx.betterem:
140+
smart_enable: all
141+
- pymdownx.caret
142+
- pymdownx.details
143+
- pymdownx.emoji:
144+
emoji_index: !!python/name:material.extensions.emoji.twemoji
145+
emoji_generator: !!python/name:material.extensions.emoji.to_svg
146+
- pymdownx.highlight
147+
- pymdownx.inlinehilite
148+
- pymdownx.keys
149+
- pymdownx.mark
150+
- pymdownx.smartsymbols
151+
- pymdownx.superfences
152+
- pymdownx.tabbed:
153+
alternate_style: true
154+
slugify: !!python/object/apply:pymdownx.slugs.slugify
155+
kwds:
156+
case: lower
157+
- pymdownx.tasklist:
158+
custom_checkbox: true
159+
- pymdownx.tilde
160+
161+
copyright: |
162+
&copy; 2024 <a href="https://github.com/pulp" target="_blank" rel="noopener">Pulp Project</a>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

docs/sections/help/index.md renamed to pulp_docs/help/index.md

+7-30

pyproject.toml

+11-7
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@ build-backend = "setuptools.build_meta"
55
[project]
66
name = "pulp-docs"
77
version = "0.0.1"
8-
requires-python = ">= 3.11"
8+
requires-python = ">= 3.12"
99
dependencies = [
10-
"mkdocs-material>=9.6.0",
11-
"mkdocstrings",
12-
"mkdocstrings-python>=1.14.1,<1.15",
13-
"mkdocs-macros-plugin",
14-
"mkdocs-site-urls",
15-
"mkdocs-literate-nav",
10+
"mkdocs~=1.6.1",
11+
"mkdocs-material~=9.6.7",
12+
"mkdocstrings~=0.29.0",
13+
"mkdocstrings-python~=1.14.1",
14+
"mkdocs-macros-plugin~=1.3.7",
15+
"mkdocs-site-urls~=0.2.0",
16+
"mkdocs-literate-nav~=0.6.1",
1617
"bs4",
1718
"httpx",
1819
"rich",
@@ -21,6 +22,9 @@ dependencies = [
2122
[project.scripts]
2223
pulp-docs = "pulp_docs.cli:main"
2324

25+
[project.entry-points."mkdocs.plugins"]
26+
PulpDocs = "pulp_docs.plugin:PulpDocsPlugin"
27+
2428
[tool.setuptools]
2529
include-package-data=true
2630

0 commit comments

Comments
 (0)