Skip to content

Commit 71fc278

Browse files
committed
fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Add a directives for general purpose documentation in downstream projects
1 parent a5319be commit 71fc278

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

django_setup_configuration/documentation/setup_config_usage.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,11 @@ def run(self):
8787
step_sections: list[nodes.section] = []
8888
if show_steps:
8989
for step in steps:
90-
step_node = nodes.section(ids=[step.anchor_id])
90+
step_node = nodes.section(ids=[step.module_path])
9191
step_node += nodes.title(text=step.title)
9292

9393
rst = ViewList()
94+
rst.append(f".. _{step.anchor_id}:", "<dynamic>")
9495
if show_steps_autodoc:
9596
rst.append(f".. autoclass:: {step.module_path}", "<dynamic>")
9697
rst.append(" :noindex:", "<dynamic>")
@@ -126,7 +127,7 @@ def _load_steps(self, configured_steps) -> list[StepInfo]: # -> list:
126127
step_cls = import_string(step_path)
127128
step_info = StepInfo(
128129
title=step_cls.verbose_name,
129-
anchor_id=f"ref-step-{step_path}",
130+
anchor_id=f"ref_step_{step_path}",
130131
module_path=step_path,
131132
step_cls=step_cls,
132133
description=step_cls.__doc__ or "",

0 commit comments

Comments
 (0)