Thread (24 messages) 24 messages, 8 authors, 2025-09-03

Re: [PATCH 00/14] Internalize www.kernel.org/doc cross-reference

From: Jani Nikula <hidden>
Date: 2025-08-29 12:18:52
Also in: bpf, damon, dri-devel, linux-block, linux-devicetree, linux-doc, linux-mm, linux-pm, linux-sound, lkml, workflows

On Fri, 29 Aug 2025, Bagas Sanjaya [off-list ref] wrote:
Cross-references to other docs (so-called internal links) are typically
done following Documentation/doc-guide/sphinx.rst: either simply
write the target docs (preferred) or use :doc: or :ref: reST directives
(for use-cases like having anchor text or cross-referencing sections).
In some places, however, links to https://www.kernel.org/doc
are used instead (outgoing, external links), owing inconsistency as
these requires Internet connection only to see docs that otherwise
can be accessed locally (after building with ``make htmldocs``).

Convert such external links to internal links. Note that this does not
cover docs.kernel.org links nor touching Documentation/tools (as
docs containing external links are in manpages).
FWIW, I'd much prefer using :ref: on rst anchors (that automatically
pick the link text from the target heading) instead of manually adding
link texts and file references.

i.e.

.. _some_target:

Heading After Some Target
=========================

See :ref:`some_target`.

Will generate "See Heading After Some Target".


BR,
Jani.


-- 
Jani Nikula, Intel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help