[Cmake-commits] CMake branch, next, updated. v3.1.0-rc2-1089-g466abce
Brad King
brad.king at kitware.com
Thu Dec 4 10:04:24 EST 2014
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, next has been updated
via 466abce5f276f99678137ea06f6a59fdf26d563c (commit)
via 607b39dc1192a9e0f7eae66f9979c399e5126337 (commit)
from 5484291dfcc5cc17c97881711d71b5f1cadfde6a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=466abce5f276f99678137ea06f6a59fdf26d563c
commit 466abce5f276f99678137ea06f6a59fdf26d563c
Merge: 5484291 607b39d
Author: Brad King <brad.king at kitware.com>
AuthorDate: Thu Dec 4 10:04:22 2014 -0500
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Dec 4 10:04:22 2014 -0500
Merge topic 'doc-mixed-case-commands' into next
607b39dc Utilities/Sphinx: Fix link targets for mixed-case command names
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=607b39dc1192a9e0f7eae66f9979c399e5126337
commit 607b39dc1192a9e0f7eae66f9979c399e5126337
Author: Brad King <brad.king at kitware.com>
AuthorDate: Thu Dec 4 09:59:43 2014 -0500
Commit: Brad King <brad.king at kitware.com>
CommitDate: Thu Dec 4 10:03:26 2014 -0500
Utilities/Sphinx: Fix link targets for mixed-case command names
When a CMake domain 'command' object is defined by CMakeTransform or the
'cmake:command' directive, generate the link target with a lower-case
name even if the command name is not all lower-case. This is needed to
make cross-references to the command definition work since the
'cmake:command' role is marked with the 'lowercase' property.
diff --git a/Utilities/Sphinx/cmake.py b/Utilities/Sphinx/cmake.py
index e20679a..5c0406d 100644
--- a/Utilities/Sphinx/cmake.py
+++ b/Utilities/Sphinx/cmake.py
@@ -201,7 +201,11 @@ class CMakeTransform(Transform):
if make_index_entry:
title = self.parse_title(env.docname)
# Insert the object link target.
- targetid = '%s:%s' % (objtype, title)
+ if objtype == 'command':
+ targetname = title.lower()
+ else:
+ targetname = title
+ targetid = '%s:%s' % (objtype, targetname)
targetnode = nodes.target('', '', ids=[targetid])
self.document.note_explicit_target(targetnode)
self.document.insert(0, targetnode)
@@ -220,7 +224,11 @@ class CMakeObject(ObjectDescription):
return sig
def add_target_and_index(self, name, sig, signode):
- targetid = '%s:%s' % (self.objtype, name)
+ if self.objtype == 'command':
+ targetname = name.lower()
+ else:
+ targetname = name
+ targetid = '%s:%s' % (self.objtype, targetname)
if targetid not in self.state.document.ids:
signode['names'].append(targetid)
signode['ids'].append(targetid)
-----------------------------------------------------------------------
Summary of changes:
Utilities/Sphinx/cmake.py | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list