File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -237,13 +237,16 @@ <h3>{{ _('Navigation') }}</h3>
237237endtrans %}
238238 {%- endif %}
239239 {%- endif %}
240+ < br />
240241 {%- if last_updated %}
241- {% trans last_updated=last_updated|e %}Last updated on {{ last_updated
242- }}.{% endtrans %}
242+ {% trans last_updated=last_updated|e %}Last updated on {{ last_updated }}.{% endtrans %}
243243 {%- endif %}
244244 {%- if show_sphinx %}
245- {% trans sphinx_version=sphinx_version|e %}Created using < a
246- href ="http://sphinx-doc.org/ "> Sphinx</ a > {{ sphinx_version }}.{% endtrans %}
245+ {% trans sphinx_version=sphinx_version|e %}Created using
246+ < ahref ="http://sphinx-doc.org/"> Sphinx</ a > {{ sphinx_version }}.{% endtrans %}
247+ {%- endif %}
248+ {%- if sha %}
249+ Doc version {{ sha }}.
247250 {%- endif %}
248251 </ div >
249252 {%- endblock %}
Original file line number Diff line number Diff line change @@ -152,11 +152,18 @@ def _check_deps():
152152master_doc = 'contents'
153153
154154# General substitutions.
155+ from matplotlib .compat .subprocess import check_output
156+ SHA = check_output (['git' , 'describe' , '--dirty' ]).decode ('utf-8' ).strip ()
157+
158+ html_context = {'sha' : SHA }
159+
155160project = 'Matplotlib'
156161copyright = ('2002 - 2012 John Hunter, Darren Dale, Eric Firing, '
157162 'Michael Droettboom and the Matplotlib development '
158163 'team; 2012 - 2018 The Matplotlib development team' )
159164
165+
166+
160167# The default replacements for |version| and |release|, also used in various
161168# other places throughout the built documents.
162169#
You can’t perform that action at this time.
0 commit comments