mirror of
https://github.com/Kitware/CMake.git
synced 2026-03-06 14:48:38 -06:00
Utilities/Sphinx: Add OpenSearch link to html page headers on cmake.org
Reference an OpenSearch description file that sits outside the content of any specific version so we only need to maintain one and so that it can reference the latest version. This was previously added in a custom branch for building the cmake.org reference documentation.
This commit is contained in:
@@ -139,6 +139,7 @@ set(doc_html_opts "")
|
||||
if(CMake_SPHINX_CMAKE_ORG)
|
||||
list(APPEND doc_html_opts
|
||||
-A googleanalytics=1
|
||||
-A opensearch=1
|
||||
-A versionswitch=1
|
||||
)
|
||||
|
||||
|
||||
@@ -31,6 +31,11 @@
|
||||
{%- endblock %}
|
||||
|
||||
{% block extrahead %}
|
||||
{%- if opensearch is defined %}
|
||||
<link rel="search" type="application/opensearchdescription+xml"
|
||||
title="Search within CMake Documentation of Latest Version"
|
||||
href="{{ pathto('../latest-opensearch.xml', 1) }}"/>
|
||||
{%- endif %}
|
||||
{%- if versionswitch is defined %}
|
||||
<script type="text/javascript" src="{{ pathto('../version_switch.js', 1) }}"></script>
|
||||
{%- endif %}
|
||||
|
||||
Reference in New Issue
Block a user