Moved Salt version infos to its own sidebar template

This commit is contained in:
Seth House 2014-04-29 16:21:25 -06:00
parent cf0b79322e
commit c3d4816275
3 changed files with 12 additions and 11 deletions

10
doc/_templates/version.html vendored Normal file
View file

@ -0,0 +1,10 @@
{% if '-g' in version %}
{% set sha = version.rsplit('-g', 1)[-1] %}
<p>These docs are for Salt's development version:
<a href="https://github.com/saltstack/salt/tree/{{ sha }}">{{ sha }}</a>.</p>
{% endif %}
<p class="muted">Docs for previous releases are available on
<a href="http://salt.readthedocs.org">salt.rtfd.org</a>.</p>
<p>Latest Salt release: <a href="{{ pathto('topics/releases/{0}'.format(release)) }}">{{ release }}</a></p>

View file

@ -61,17 +61,6 @@
<div>
{%- block sidebarlogo %}{%- endblock %}
{% if '-g' in version %}
{% set sha = version.rsplit('-g', 1)[-1] %}
<p>These docs are for Salt's development version:
<a href="https://github.com/saltstack/salt/tree/{{ sha }}">{{ sha }}</a>.</p>
{% endif %}
<p class="muted">Docs for previous releases are available on
<a href="http://salt.readthedocs.org">salt.rtfd.org</a>.</p>
<p>Latest Salt release: <a href="{{ pathto('topics/releases/{0}'.format(release)) }}">{{ release }}</a></p>
{%- for sidebartemplate in sidebars|default(html_default_sidebars, true) %}
{%- include sidebartemplate %}
{%- endfor %}

View file

@ -193,6 +193,7 @@ html_additional_pages = {
}
html_default_sidebars = [
'version.html',
'localtoc.html',
'relations.html',
'sourcelink.html',
@ -200,6 +201,7 @@ html_default_sidebars = [
]
html_sidebars = {
'ref/**/all/salt.*': [
'version.html',
'modules-sidebar.html',
'localtoc.html',
'relations.html',