Hello,
I want to set several links to external documentation (for
example
https://cmake.org/cmake/help/v3.13/command/add_library.html?highlight=add_library#imported-libraries).
In this example, there is a version number and in case, that this version
number changes, I don't want to change the links in several places. So I
want to define the trunk of that link at one place and reuse it. My first
thought was, I could use `replace::` for that:
.. |CMakeDocumentationRoot| replace:: cmake.org/cmake/help/v3.13/
And then set links like this for example:
.. seealso::
add_library_
.. _add_library:
https://|CMakeDocumentationRoot|variable/CMAKE_VERSION.html#variable:CMAKE_VERSION
This doesn't work because the replacement is not done within the link text.
Second idea was to search for an appropriate plugin. sphinx.ext.extlinks
would do the trick if the target URLs would be more simple structured.
Does someone of you have an idea, how to include URLs in a documentation,
which have a common trunk?
Kind regards,
Torsten
P.S: As a side-topic: I'm unable to find any documentation for the
"replace" command. What are you using as reference for Sphinx and RST?
--
You received this message because you are subscribed to the Google Groups
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/d/optout.