summaryrefslogtreecommitdiffstats
path: root/Utilities
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-01-14 13:56:57 (GMT)
committerKitware Robot <kwrobot@kitware.com>2020-01-14 13:58:38 (GMT)
commitf1af6d5baf2ce7d36e877d13153e0a399562d30b (patch)
tree0b55bbfedd7ad32d80f1eabff7be9d77f1311223 /Utilities
parent09c43466e5f6a61746237a48c1469a4f6cc0da0f (diff)
parentbd681fee7a0f0fb95af4a71255774b52f9ea26da (diff)
downloadCMake-f1af6d5baf2ce7d36e877d13153e0a399562d30b.zip
CMake-f1af6d5baf2ce7d36e877d13153e0a399562d30b.tar.gz
CMake-f1af6d5baf2ce7d36e877d13153e0a399562d30b.tar.bz2
Merge topic 'doc-user-interaction'
bd681fee7a Help: Add guides for user interaction 6185265800 Utilities/Sphinx: Index guide-level documents for cross-referencing b1b7d01172 Utilities/Sphinx: Index document types only by top level directory Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Mateusz Łoskot <mateusz@loskot.net> Acked-by: Daan De Meyer <daan.j.demeyer@gmail.com> Merge-request: !4097
Diffstat (limited to 'Utilities')
-rw-r--r--Utilities/Sphinx/cmake.py5
-rwxr-xr-xUtilities/Sphinx/create_identifiers.py1
2 files changed, 5 insertions, 1 deletions
diff --git a/Utilities/Sphinx/cmake.py b/Utilities/Sphinx/cmake.py
index d903dbe..f164fd0 100644
--- a/Utilities/Sphinx/cmake.py
+++ b/Utilities/Sphinx/cmake.py
@@ -191,6 +191,7 @@ _cmake_index_objs = {
'cpack_gen': _cmake_index_entry('cpack generator'),
'envvar': _cmake_index_entry('envvar'),
'generator': _cmake_index_entry('generator'),
+ 'guide': _cmake_index_entry('guide'),
'manual': _cmake_index_entry('manual'),
'module': _cmake_index_entry('module'),
'policy': _cmake_index_entry('policy'),
@@ -251,7 +252,7 @@ class CMakeTransform(Transform):
env = self.document.settings.env
# Treat some documents as cmake domain objects.
- objtype, sep, tail = env.docname.rpartition('/')
+ objtype, sep, tail = env.docname.partition('/')
make_index_entry = _cmake_index_objs.get(objtype)
if make_index_entry:
title = self.parse_title(env.docname)
@@ -373,6 +374,7 @@ class CMakeDomain(Domain):
'cpack_gen': ObjType('cpack_gen', 'cpack_gen'),
'envvar': ObjType('envvar', 'envvar'),
'generator': ObjType('generator', 'generator'),
+ 'guide': ObjType('guide', 'guide'),
'variable': ObjType('variable', 'variable'),
'module': ObjType('module', 'module'),
'policy': ObjType('policy', 'policy'),
@@ -407,6 +409,7 @@ class CMakeDomain(Domain):
'cpack_gen': CMakeXRefRole(),
'envvar': CMakeXRefRole(),
'generator': CMakeXRefRole(),
+ 'guide': CMakeXRefRole(),
'variable': CMakeXRefRole(),
'module': CMakeXRefRole(),
'policy': CMakeXRefRole(),
diff --git a/Utilities/Sphinx/create_identifiers.py b/Utilities/Sphinx/create_identifiers.py
index 6716b48..b5cd914 100755
--- a/Utilities/Sphinx/create_identifiers.py
+++ b/Utilities/Sphinx/create_identifiers.py
@@ -25,6 +25,7 @@ for line in lines:
("envvar", "envvar"),
("variable", "variable"),
("generator", "generator"),
+ ("guide", "guide"),
("target property", "prop_tgt"),
("test property", "prop_test"),
("source file property", "prop_sf"),