Docs tests: remove leading slash (#7170)

* Docs tests: remove leading slash

* Fix slash handling in link-data.json for the C++ docs

* Fix trailing slash handling for link-data.json for the Rust API docs

---------

Co-authored-by: Simon Hausmann <simon.hausmann@slint.dev>
This commit is contained in:
Nigel Breslaw 2024-12-19 14:01:49 +02:00 committed by GitHub
parent 51282976db
commit 3fae8b2a9a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 67 additions and 67 deletions

View file

@ -130,7 +130,7 @@ with open(os.path.join(os.path.dirname(__file__), "..", "..", "internal", "core-
for key in links.keys():
href = links[key]["href"]
url = f"https://slint.dev/releases/{version}/docs/slint{href}"
url = f"https://slint.dev/releases/{version}/docs/slint/{href}"
myst_substitutions[f"slint_href_{key}"] = url
rst_epilog += f".. |{key}| replace:: :code:`{key}`\n"
rst_epilog += f".. _{key}: {url}\n"