From c00106b20f3a6421a2df86793ec01bfc88871c08 Mon Sep 17 00:00:00 2001 From: Matthew Woehlke Date: Tue, 28 Jul 2026 17:01:59 -0400 Subject: [PATCH] Help: Improve formatting of presets manual Tweak how we reference preset macros so that references also carry 'literal' markup. While this provides a modest improvement to HTML rendered help, it primarily serves to apply 'literal' formatting consistently for TTY output (`cmake --help-presets`). --- Help/manual/cmake-presets.7.rst | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/Help/manual/cmake-presets.7.rst b/Help/manual/cmake-presets.7.rst index 732287c113..06340318db 100644 --- a/Help/manual/cmake-presets.7.rst +++ b/Help/manual/cmake-presets.7.rst @@ -268,6 +268,7 @@ Recognized macros include: This is a preset-specific macro. .. _`CMakePresets hostSystemName`: +.. |CMakePresets hostSystemName| replace:: ``${hostSystemName}`` ``${hostSystemName}`` .. presets-versionadded:: 3 @@ -276,6 +277,7 @@ Recognized macros include: :variable:`CMAKE_HOST_SYSTEM_NAME`. .. _`CMakePresets fileDir`: +.. |CMakePresets fileDir| replace:: ``${fileDir}`` ``${fileDir}`` .. presets-versionadded:: 4 @@ -316,6 +318,7 @@ Recognized macros include: A literal dollar sign (``$``). .. _`CMakePresets pathListSep`: +.. |CMakePresets pathListSep| replace:: ``${pathListSep}`` ``${pathListSep}`` .. presets-versionadded:: 5 @@ -395,7 +398,7 @@ they were added and a summary of the new features and changes is given below. * Changes to `Macro Expansion`_ - * The `${hostSystemName} `_ macro was + * The |CMakePresets hostSystemName|_ macro was added. ``4`` @@ -409,7 +412,7 @@ they were added and a summary of the new features and changes is given below. * Changes to `Macro Expansion`_ - * The `${fileDir} `_ macro was added. + * The |CMakePresets fileDir|_ macro was added. ``5`` .. versionadded:: 3.24 @@ -421,7 +424,7 @@ they were added and a summary of the new features and changes is given below. * Changes to `Macro Expansion`_ - * The `${pathListSep} `_ macro was added. + * The |CMakePresets pathListSep|_ macro was added. ``6`` .. versionadded:: 3.25 @@ -491,10 +494,9 @@ they were added and a summary of the new features and changes is given below. * Changes to `Macro Expansion`_ - * The `${fileDir} `_ macro now always expands to - the directory of presets file containing the ``${fileDir}`` macro, - regardless of whether it is inherited by another preset in a different - directory. + * The |CMakePresets fileDir|_ macro now always expands to the directory + of presets file containing the ``${fileDir}`` macro, regardless of + whether it is inherited by another preset in a different directory. * Changes to `Test Presets `_