doc: extensions: kconfig: fix module prefix handling
If two modules started with the same prefix, e.g. nrf and nrfxlib, the file name prefix was incorrectly set with the common prefix. Include trailing "/" to the comparison, so that we match the full module name. Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
This commit is contained in:
parent
23f0578042
commit
d3c0e95f97
1 changed files with 2 additions and 1 deletions
|
@ -354,8 +354,9 @@ def kconfig_build_resources(app: Sphinx) -> None:
|
||||||
|
|
||||||
filename = node.filename
|
filename = node.filename
|
||||||
for name, path in module_paths.items():
|
for name, path in module_paths.items():
|
||||||
|
path += "/"
|
||||||
if node.filename.startswith(path):
|
if node.filename.startswith(path):
|
||||||
filename = node.filename.replace(path, f"<module:{name}>")
|
filename = node.filename.replace(path, f"<module:{name}>/")
|
||||||
break
|
break
|
||||||
|
|
||||||
db.append(
|
db.append(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue