Skip to content

Commit

Permalink
FIX: support linkcheck builder
Browse files Browse the repository at this point in the history
  • Loading branch information
redeboer committed Dec 5, 2023
1 parent 5c661be commit 265aaba
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/sphinx_api_relink/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ def setup(app: Sphinx) -> dict[str, Any]:


def set_linkcode_resolve(app: Sphinx, _: BuildEnvironment) -> None:
raw_config = app.config._raw_config # pyright: ignore[reportPrivateUsage]
github_repo: str | None = app.config.api_github_repo
if github_repo is None:
msg = (
Expand All @@ -46,7 +45,7 @@ def set_linkcode_resolve(app: Sphinx, _: BuildEnvironment) -> None:
)
raise ValueError(msg)
debug: bool = app.config.api_linkcode_debug
raw_config["linkcode_resolve"] = get_linkcode_resolve(github_repo, debug)
app.config.linkcode_resolve = get_linkcode_resolve(github_repo, debug) # type: ignore[attr-defined]


def generate_apidoc(app: Sphinx, _: BuildEnvironment) -> None:
Expand Down

0 comments on commit 265aaba

Please sign in to comment.