bpo-28929: Link the documentation to its source file on GitHub (#38) · python/cpython@e15259c (original) (raw)

Original file line number Diff line number Diff line change
@@ -45,8 +45,9 @@
45 45 <h3>{{ _('This Page') }}</h3>
46 46 <ul class="this-page-menu">
47 47 <li><a href="{{ pathto('bugs') }}">{% trans %}Report a Bug{% endtrans %}</a></li>
48 -<li><a href="{{ pathto('_sources/' + sourcename, true)|e }}"
49 -rel="nofollow">{% trans %}Show Source{% endtrans %}</a></li>
48 +<li><a href="https://github.com/python/cpython/blob/{{ version }}/Doc/{{ sourcename|replace('txt', 'rst') }}"
49 +rel="nofollow">{% trans %}Show Source{% endtrans %}</a>
50 +</li>
50 51 </ul>
51 52 {%- endif %}
52 53 {% endblock %}