[LTP] [PATCH 1/1] doc: Link struct tst_test and tst_tag
Andrea Cervesato
andrea.cervesato@suse.com
Thu Feb 20 13:42:37 CET 2025
Hi,
mmh..result looks really weird. Basically every table item is a link to
tst_test. Did you check if it's possible to extend the struct parser in
order to have a link for each attribute?
Andrea
On 2/19/25 17:01, Petr Vorel wrote:
> Although it's currently impossible to link to tst_test members,
> it's still useful to make links to allow user to read the actual code.
>
> Signed-off-by: Petr Vorel <pvorel@suse.cz>
> ---
> doc/conf.py | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/doc/conf.py b/doc/conf.py
> index 2be847d90b..8cc890fcc8 100644
> --- a/doc/conf.py
> +++ b/doc/conf.py
> @@ -286,7 +286,7 @@ def _generate_tags_table(tags):
> tag_val = f'`{tag_val} <{tag_url}{tag_val}>`_'
>
> table.extend([
> - f' * - {tag_key}',
> + f' * - :c:struct:`{tag_key} <tst_tag>`',
> f' - {tag_val}',
> ])
>
> @@ -331,6 +331,7 @@ def _generate_table_cell(key, values):
> Generate a cell which can be multiline if value is a list.
> """
> cell = []
> + key = f' :c:struct:`{key} <tst_test>`'
>
> if len(values) > 1:
> cell.extend([
More information about the ltp
mailing list