pyi matching

This commit is contained in:
2026-01-21 00:43:27 +05:30
parent be8f23c8ab
commit 81e8a8cd49
4 changed files with 8 additions and 9 deletions

View File

@@ -1,10 +1,11 @@
from .loader import GriffeLoader
from .loader import GriffeLoader, discover_module_paths
from .renderers import MkDocsRenderer
from .cli import main
from . import model
__all__ = [
"GriffeLoader",
"discover_module_paths",
"MkDocsRenderer",
"model",
"main",

View File

@@ -28,8 +28,7 @@ def tree(
@cli.command()
@click.option(
"--modules",
multiple=True,
"--module",
help="Python module import paths to document",
)
@click.option(
@@ -42,7 +41,7 @@ def tree(
default=Path("docs"),
)
def generate(
modules: Sequence[str],
module: str,
project_name: str | None,
docs_dir: Path,
) -> None:

View File

@@ -27,7 +27,7 @@ class MkDocsNavEmitter:
"""
...
def _to_relative(self, path: Path) -> str:
def _to_relative(self, path: Path, docs_root: Path | None) -> str:
"""
Convert a filesystem path to a docs-relative path.
"""

View File

@@ -15,15 +15,14 @@ class ResolvedNav:
home: Optional[str]
groups: Dict[str, List[Path]]
_docs_root: Optional[Path]
def __init__(
self,
home: str | None,
groups: Dict[str, List[Path]],
docs_root: Path | None = None,
) -> None:
self._docs_root = None
...
docs_root: Path | None = ...,
) -> None: ...
def all_files(self) -> Iterable[Path]:
"""