docs: refresh doc-forge library and MCP bundle
- collect regenerated doc-forge combined site (wiki + lib) - drop stale lib/docforge duplicate subtree - mcp bundle now uses docs:// module resources
This commit is contained in:
@@ -37,14 +37,14 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.NavSpec.load",
|
||||
"signature": "<bound method Alias.signature of Alias('load', 'docforge.nav.spec.NavSpec.load')>",
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path: Filesystem path to the navigation specification file.\n\nReturns:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path (Path):\n Filesystem path to the navigation specification file.\n\nReturns:\n NavSpec:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
},
|
||||
"all_patterns": {
|
||||
"name": "all_patterns",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.NavSpec.all_patterns",
|
||||
"signature": "<bound method Alias.signature of Alias('all_patterns', 'docforge.nav.spec.NavSpec.all_patterns')>",
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n list[str]:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -53,7 +53,7 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.load_nav_spec",
|
||||
"signature": "<bound method Alias.signature of Alias('load_nav_spec', 'docforge.nav.spec.load_nav_spec')>",
|
||||
"docstring": "Load a navigation specification file.\n\nThis helper function reads a YAML navigation file and constructs a\ncorresponding ``NavSpec`` instance.\n\nArgs:\n path: Path to the navigation specification file.\n\nReturns:\n A ``NavSpec`` instance representing the parsed specification.\n\nRaises:\n FileNotFoundError: If the specification file does not exist.\n ValueError: If the YAML structure is invalid."
|
||||
"docstring": "Load a navigation specification file.\n\nThis helper function reads a YAML navigation file and constructs a\ncorresponding ``NavSpec`` instance.\n\nArgs:\n path (Path):\n Path to the navigation specification file.\n\nReturns:\n NavSpec:\n A ``NavSpec`` instance representing the parsed specification.\n\nRaises:\n FileNotFoundError: If the specification file does not exist.\n ValueError: If the YAML structure is invalid."
|
||||
},
|
||||
"ResolvedNav": {
|
||||
"name": "ResolvedNav",
|
||||
@@ -81,7 +81,7 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.ResolvedNav.all_files",
|
||||
"signature": "<bound method Alias.signature of Alias('all_files', 'docforge.nav.resolver.ResolvedNav.all_files')>",
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nReturns:\n An iterable of ``Path`` objects representing documentation files.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nYields:\n Path:\n A documentation file referenced by the navigation, including\n the home page when defined.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -90,7 +90,7 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.resolve_nav",
|
||||
"signature": "<bound method Alias.signature of Alias('resolve_nav', 'docforge.nav.resolver.resolve_nav')>",
|
||||
"docstring": "Resolve a navigation specification against the filesystem.\n\nThe function expands glob patterns defined in a ``NavSpec`` and verifies\nthat referenced documentation files exist within the documentation root.\n\nArgs:\n spec: Navigation specification describing documentation layout.\n docs_root: Root directory containing documentation Markdown files.\n\nReturns:\n A ``ResolvedNav`` instance containing validated navigation paths.\n\nRaises:\n FileNotFoundError: If the documentation root does not exist or a\n navigation pattern does not match any files."
|
||||
"docstring": "Resolve a navigation specification against the filesystem.\n\nThe function expands glob patterns defined in a ``NavSpec`` and verifies\nthat referenced documentation files exist within the documentation root.\n\nArgs:\n spec (NavSpec):\n Navigation specification describing documentation layout.\n docs_root (Path):\n Root directory containing documentation Markdown files.\n\nReturns:\n ResolvedNav:\n A `ResolvedNav` instance containing validated navigation paths.\n\nRaises:\n FileNotFoundError: If the documentation root does not exist or a\n navigation pattern does not match any files."
|
||||
},
|
||||
"MkDocsNavEmitter": {
|
||||
"name": "MkDocsNavEmitter",
|
||||
@@ -104,16 +104,23 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.MkDocsNavEmitter.emit",
|
||||
"signature": "<bound method Alias.signature of Alias('emit', 'docforge.nav.mkdocs.MkDocsNavEmitter.emit')>",
|
||||
"docstring": "Generate a navigation structure for ``mkdocs.yml``.\n\nArgs:\n nav: Resolved navigation data describing documentation groups\n and their associated Markdown files.\n\nReturns:\n A list of dictionaries representing the MkDocs navigation layout.\n Each dictionary maps a navigation label to a page or a list of\n pages."
|
||||
"docstring": "Generate a navigation structure for ``mkdocs.yml``.\n\nArgs:\n nav (ResolvedNav):\n Resolved navigation data describing documentation groups\n and their associated Markdown files.\n\nReturns:\n list[dict[str, Any]]:\n A list of dictionaries representing the MkDocs navigation layout.\n Each dictionary maps a navigation label to a page or a list of\n pages."
|
||||
}
|
||||
}
|
||||
},
|
||||
"build_wiki_nav": {
|
||||
"name": "build_wiki_nav",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.build_wiki_nav",
|
||||
"signature": "<bound method Alias.signature of Alias('build_wiki_nav', 'docforge.nav.wiki.build_wiki_nav')>",
|
||||
"docstring": "Derive an MkDocs navigation block from a wiki directory.\n\nReturned paths are relative to the parent of ``wiki_dir`` and carry the\nwiki directory name as their leading component (for example\n``wiki/01_overview.md`` when the wiki lives at ``docs/wiki``). This makes\nthe result directly usable in an MkDocs ``nav`` block with\n\n- ``index.md`` at the wiki root becomes the ``Home`` entry.\n- Page labels are derived from filenames: numeric order prefixes such as\n ``01_`` or ``02-`` are stripped, separators are replaced with spaces, and\n names are title-cased (``01_overview.md`` becomes ``Overview``).\n- Subdirectories become nested navigation groups. A nested ``index.md`` is\n rendered as the section root placed first inside the group.\n- Only ``.md`` files are considered; hidden entries are ignored.\n\nArgs:\n wiki_dir (Path):\n Path to the hand-written wiki directory, for example ``docs/wiki``.\n\nReturns:\n list[dict[str, Any]]:\n Navigation entries compatible with the MkDocs ``nav`` configuration.\n The list is empty if the wiki contains no Markdown files.\n\nRaises:\n FileNotFoundError:\n If the wiki directory does not exist."
|
||||
},
|
||||
"mkdocs": {
|
||||
"name": "mkdocs",
|
||||
"kind": "module",
|
||||
"path": "docforge.nav.mkdocs",
|
||||
"signature": null,
|
||||
"docstring": "MkDocs navigation emitter.\n\nThis module provides the ``MkDocsNavEmitter`` class, which converts a\n``ResolvedNav`` instance into the navigation structure required by the\nMkDocs ``nav`` configuration.",
|
||||
"docstring": "MkDocs navigation emitter.\n\nThis module provides the ``MkDocsNavEmitter`` class, which converts a\n``ResolvedNav`` instance into the navigation structure required by the\nMkDocs ``nav`` configuration.\n\n---\n\nNotes:\n - The emitted structure is a list of dictionaries, one per top-level nav\n entry, matching the MkDocs ``nav`` YAML format.\n\n---",
|
||||
"members": {
|
||||
"Path": {
|
||||
"name": "Path",
|
||||
@@ -155,7 +162,7 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.mkdocs.ResolvedNav.all_files",
|
||||
"signature": "<bound method Alias.signature of Alias('all_files', 'docforge.nav.resolver.ResolvedNav.all_files')>",
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nReturns:\n An iterable of ``Path`` objects representing documentation files.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nYields:\n Path:\n A documentation file referenced by the navigation, including\n the home page when defined.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -163,15 +170,15 @@
|
||||
"name": "MkDocsNavEmitter",
|
||||
"kind": "class",
|
||||
"path": "docforge.nav.mkdocs.MkDocsNavEmitter",
|
||||
"signature": "<bound method Class.signature of Class('MkDocsNavEmitter', 15, 81)>",
|
||||
"signature": "<bound method Class.signature of Class('MkDocsNavEmitter', 23, 94)>",
|
||||
"docstring": "Emit MkDocs navigation structures from resolved navigation data.\n\nThe emitter transforms a ``ResolvedNav`` object into the YAML-compatible\nlist structure expected by the MkDocs ``nav`` configuration field.",
|
||||
"members": {
|
||||
"emit": {
|
||||
"name": "emit",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.mkdocs.MkDocsNavEmitter.emit",
|
||||
"signature": "<bound method Function.signature of Function('emit', 23, 51)>",
|
||||
"docstring": "Generate a navigation structure for ``mkdocs.yml``.\n\nArgs:\n nav: Resolved navigation data describing documentation groups\n and their associated Markdown files.\n\nReturns:\n A list of dictionaries representing the MkDocs navigation layout.\n Each dictionary maps a navigation label to a page or a list of\n pages."
|
||||
"signature": "<bound method Function.signature of Function('emit', 31, 61)>",
|
||||
"docstring": "Generate a navigation structure for ``mkdocs.yml``.\n\nArgs:\n nav (ResolvedNav):\n Resolved navigation data describing documentation groups\n and their associated Markdown files.\n\nReturns:\n list[dict[str, Any]]:\n A list of dictionaries representing the MkDocs navigation layout.\n Each dictionary maps a navigation label to a page or a list of\n pages."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -182,7 +189,7 @@
|
||||
"kind": "module",
|
||||
"path": "docforge.nav.resolver",
|
||||
"signature": null,
|
||||
"docstring": "Navigation resolution utilities.\n\nThis module resolves a ``NavSpec`` against the filesystem by expanding glob\npatterns and validating that referenced documentation files exist.",
|
||||
"docstring": "Navigation resolution utilities.\n\nThis module resolves a ``NavSpec`` against the filesystem by expanding glob\npatterns and validating that referenced documentation files exist.\n\n---\n\nNotes:\n - Glob resolution is recursive and returns paths in sorted order.\n - Unmatched patterns raise ``FileNotFoundError`` to fail fast on typos.\n\n---",
|
||||
"members": {
|
||||
"glob": {
|
||||
"name": "glob",
|
||||
@@ -238,14 +245,14 @@
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.resolver.NavSpec.load",
|
||||
"signature": "<bound method Alias.signature of Alias('load', 'docforge.nav.spec.NavSpec.load')>",
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path: Filesystem path to the navigation specification file.\n\nReturns:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path (Path):\n Filesystem path to the navigation specification file.\n\nReturns:\n NavSpec:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
},
|
||||
"all_patterns": {
|
||||
"name": "all_patterns",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.resolver.NavSpec.all_patterns",
|
||||
"signature": "<bound method Alias.signature of Alias('all_patterns', 'docforge.nav.spec.NavSpec.all_patterns')>",
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n list[str]:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -253,7 +260,7 @@
|
||||
"name": "ResolvedNav",
|
||||
"kind": "class",
|
||||
"path": "docforge.nav.resolver.ResolvedNav",
|
||||
"signature": "<bound method Class.signature of Class('ResolvedNav', 15, 63)>",
|
||||
"signature": "<bound method Class.signature of Class('ResolvedNav', 23, 76)>",
|
||||
"docstring": "Resolved navigation structure.\n\nA ``ResolvedNav`` represents navigation data after glob patterns have been\nexpanded and paths validated against the filesystem.\n\nAttributes:\n home: Relative path to the documentation home page.\n groups: Mapping of navigation group titles to lists of resolved\n documentation file paths.",
|
||||
"members": {
|
||||
"home": {
|
||||
@@ -274,8 +281,8 @@
|
||||
"name": "all_files",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.resolver.ResolvedNav.all_files",
|
||||
"signature": "<bound method Function.signature of Function('all_files', 46, 63)>",
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nReturns:\n An iterable of ``Path`` objects representing documentation files.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
"signature": "<bound method Function.signature of Function('all_files', 57, 76)>",
|
||||
"docstring": "Iterate over all files referenced by the navigation structure.\n\nYields:\n Path:\n A documentation file referenced by the navigation, including\n the home page when defined.\n\nRaises:\n RuntimeError: If the home page is defined but the documentation\n root is not available for resolution."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -283,8 +290,8 @@
|
||||
"name": "resolve_nav",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.resolver.resolve_nav",
|
||||
"signature": "<bound method Function.signature of Function('resolve_nav', 66, 132)>",
|
||||
"docstring": "Resolve a navigation specification against the filesystem.\n\nThe function expands glob patterns defined in a ``NavSpec`` and verifies\nthat referenced documentation files exist within the documentation root.\n\nArgs:\n spec: Navigation specification describing documentation layout.\n docs_root: Root directory containing documentation Markdown files.\n\nReturns:\n A ``ResolvedNav`` instance containing validated navigation paths.\n\nRaises:\n FileNotFoundError: If the documentation root does not exist or a\n navigation pattern does not match any files."
|
||||
"signature": "<bound method Function.signature of Function('resolve_nav', 79, 150)>",
|
||||
"docstring": "Resolve a navigation specification against the filesystem.\n\nThe function expands glob patterns defined in a ``NavSpec`` and verifies\nthat referenced documentation files exist within the documentation root.\n\nArgs:\n spec (NavSpec):\n Navigation specification describing documentation layout.\n docs_root (Path):\n Root directory containing documentation Markdown files.\n\nReturns:\n ResolvedNav:\n A `ResolvedNav` instance containing validated navigation paths.\n\nRaises:\n FileNotFoundError: If the documentation root does not exist or a\n navigation pattern does not match any files."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -293,8 +300,15 @@
|
||||
"kind": "module",
|
||||
"path": "docforge.nav.spec",
|
||||
"signature": null,
|
||||
"docstring": "Navigation specification model.\n\nThis module defines the ``NavSpec`` class, which represents the navigation\nstructure defined by the user in the doc-forge navigation specification\n(typically ``docforge.nav.yml``).",
|
||||
"docstring": "Navigation specification model.\n\nThis module defines the ``NavSpec`` class, which represents the navigation\nstructure defined by the user in the doc-forge navigation specification\n(typically ``docforge.nav.yml``).\n\n---\n\nNotes:\n - The spec file supports an optional ``icon`` mapping for MkDocs theme\n customization.\n - All file references in ``groups`` are relative to the documentation root.\n\n---",
|
||||
"members": {
|
||||
"annotations": {
|
||||
"name": "annotations",
|
||||
"kind": "alias",
|
||||
"path": "docforge.nav.spec.annotations",
|
||||
"signature": "<bound method Alias.signature of Alias('annotations', '__future__.annotations')>",
|
||||
"docstring": null
|
||||
},
|
||||
"Path": {
|
||||
"name": "Path",
|
||||
"kind": "alias",
|
||||
@@ -313,7 +327,7 @@
|
||||
"name": "NavSpec",
|
||||
"kind": "class",
|
||||
"path": "docforge.nav.spec.NavSpec",
|
||||
"signature": "<bound method Class.signature of Class('NavSpec', 14, 119)>",
|
||||
"signature": "<bound method Class.signature of Class('NavSpec', 25, 136)>",
|
||||
"docstring": "Parsed representation of a navigation specification.\n\nA ``NavSpec`` describes the intended documentation navigation layout before\nit is resolved against the filesystem.\n\nAttributes:\n home: Relative path to the documentation home page (for example\n ``index.md``).\n groups: Mapping of navigation group titles to lists of file patterns\n or glob expressions.\n icon: Optional mapping of theme icon entries (for example\n ``{\"logo\": \"material/code-tags\"}``) injected into the MkDocs\n theme as ``theme.icon``.",
|
||||
"members": {
|
||||
"home": {
|
||||
@@ -341,15 +355,15 @@
|
||||
"name": "load",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.spec.NavSpec.load",
|
||||
"signature": "<bound method Function.signature of Function('load', 51, 101)>",
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path: Filesystem path to the navigation specification file.\n\nReturns:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
"signature": "<bound method Function.signature of Function('load', 65, 117)>",
|
||||
"docstring": "Load a navigation specification from a YAML file.\n\nArgs:\n path (Path):\n Filesystem path to the navigation specification file.\n\nReturns:\n NavSpec:\n A ``NavSpec`` instance representing the parsed configuration.\n\nRaises:\n FileNotFoundError: If the specified file does not exist.\n ValueError: If the file contents are not a valid navigation\n specification."
|
||||
},
|
||||
"all_patterns": {
|
||||
"name": "all_patterns",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.spec.NavSpec.all_patterns",
|
||||
"signature": "<bound method Function.signature of Function('all_patterns', 103, 119)>",
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
"signature": "<bound method Function.signature of Function('all_patterns', 119, 136)>",
|
||||
"docstring": "Return all path patterns referenced by the specification.\n\nReturns:\n list[str]:\n A list containing the home document (if defined) and all\n group pattern entries."
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -357,8 +371,52 @@
|
||||
"name": "load_nav_spec",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.spec.load_nav_spec",
|
||||
"signature": "<bound method Function.signature of Function('load_nav_spec', 122, 151)>",
|
||||
"docstring": "Load a navigation specification file.\n\nThis helper function reads a YAML navigation file and constructs a\ncorresponding ``NavSpec`` instance.\n\nArgs:\n path: Path to the navigation specification file.\n\nReturns:\n A ``NavSpec`` instance representing the parsed specification.\n\nRaises:\n FileNotFoundError: If the specification file does not exist.\n ValueError: If the YAML structure is invalid."
|
||||
"signature": "<bound method Function.signature of Function('load_nav_spec', 139, 170)>",
|
||||
"docstring": "Load a navigation specification file.\n\nThis helper function reads a YAML navigation file and constructs a\ncorresponding ``NavSpec`` instance.\n\nArgs:\n path (Path):\n Path to the navigation specification file.\n\nReturns:\n NavSpec:\n A ``NavSpec`` instance representing the parsed specification.\n\nRaises:\n FileNotFoundError: If the specification file does not exist.\n ValueError: If the YAML structure is invalid."
|
||||
}
|
||||
}
|
||||
},
|
||||
"wiki": {
|
||||
"name": "wiki",
|
||||
"kind": "module",
|
||||
"path": "docforge.nav.wiki",
|
||||
"signature": null,
|
||||
"docstring": "# Summary\n\nWiki navigation derivation.\n\nThis module provides ``build_wiki_nav``, which derives an MkDocs-ready\nnavigation block from the file structure of a hand-written wiki directory\n(typically ``docs/wiki``). wiki content is authored by hand and is never\nmodified by doc-forge; only the navigation layout is inferred.\n\n# Notes\n\n- ``index.md`` at the wiki root becomes the ``Home`` entry.\n- Page labels are derived from filenames: numeric order prefixes such as\n ``01_`` or ``02-`` are stripped, separators are replaced with spaces, and\n names are title-cased (``01_overview.md`` becomes ``Overview``).\n- Subdirectories become nested navigation groups. A nested ``index.md`` is\n rendered as the section root placed first inside the group.\n- Only ``.md`` files are considered; hidden entries are ignored.",
|
||||
"members": {
|
||||
"re": {
|
||||
"name": "re",
|
||||
"kind": "alias",
|
||||
"path": "docforge.nav.wiki.re",
|
||||
"signature": "<bound method Alias.signature of Alias('re', 're')>",
|
||||
"docstring": null
|
||||
},
|
||||
"Callable": {
|
||||
"name": "Callable",
|
||||
"kind": "alias",
|
||||
"path": "docforge.nav.wiki.Callable",
|
||||
"signature": "<bound method Alias.signature of Alias('Callable', 'collections.abc.Callable')>",
|
||||
"docstring": null
|
||||
},
|
||||
"Path": {
|
||||
"name": "Path",
|
||||
"kind": "alias",
|
||||
"path": "docforge.nav.wiki.Path",
|
||||
"signature": "<bound method Alias.signature of Alias('Path', 'pathlib.Path')>",
|
||||
"docstring": null
|
||||
},
|
||||
"Any": {
|
||||
"name": "Any",
|
||||
"kind": "alias",
|
||||
"path": "docforge.nav.wiki.Any",
|
||||
"signature": "<bound method Alias.signature of Alias('Any', 'typing.Any')>",
|
||||
"docstring": null
|
||||
},
|
||||
"build_wiki_nav": {
|
||||
"name": "build_wiki_nav",
|
||||
"kind": "function",
|
||||
"path": "docforge.nav.wiki.build_wiki_nav",
|
||||
"signature": "<bound method Function.signature of Function('build_wiki_nav', 28, 76)>",
|
||||
"docstring": "Derive an MkDocs navigation block from a wiki directory.\n\nReturned paths are relative to the parent of ``wiki_dir`` and carry the\nwiki directory name as their leading component (for example\n``wiki/01_overview.md`` when the wiki lives at ``docs/wiki``). This makes\nthe result directly usable in an MkDocs ``nav`` block with\n\n- ``index.md`` at the wiki root becomes the ``Home`` entry.\n- Page labels are derived from filenames: numeric order prefixes such as\n ``01_`` or ``02-`` are stripped, separators are replaced with spaces, and\n names are title-cased (``01_overview.md`` becomes ``Overview``).\n- Subdirectories become nested navigation groups. A nested ``index.md`` is\n rendered as the section root placed first inside the group.\n- Only ``.md`` files are considered; hidden entries are ignored.\n\nArgs:\n wiki_dir (Path):\n Path to the hand-written wiki directory, for example ``docs/wiki``.\n\nReturns:\n list[dict[str, Any]]:\n Navigation entries compatible with the MkDocs ``nav`` configuration.\n The list is empty if the wiki contains no Markdown files.\n\nRaises:\n FileNotFoundError:\n If the wiki directory does not exist."
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user