From 993b57b8ea577f2120f7d0c81b45ee5ed74a0f57 Mon Sep 17 00:00:00 2001 From: Dmitry Shachnev Date: Mon, 18 Mar 2024 00:21:30 +0300 Subject: [PATCH] Fixed links to source code on GitHub from the documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit With the current version, if you open e.g. this page: https://python-markdown.github.io/reference/markdown/blockprocessors/ The ‹› links on the right side of the page will point to URLs like https://github.com/Python-Markdown/markdown/tree/3.6//home/runner/work/markdown/markdown/md/markdown/blockprocessors.py This commit fixes them by replacing `filepath` with `relative_filepath`. --- docs/changelog.md | 6 ++++++ docs/templates/python/nature/attribute.html | 2 +- docs/templates/python/nature/class.html | 2 +- docs/templates/python/nature/function.html | 2 +- docs/templates/python/nature/module.html | 2 +- 5 files changed, 10 insertions(+), 4 deletions(-) diff --git a/docs/changelog.md b/docs/changelog.md index ad0aa04c7..86b3b5fd7 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -8,6 +8,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). See the [Contributing Guide](contributing.md) for details. +## [unreleased] + +### Fixed + +* Fixed links to source code on GitHub from the documentation (#1453). + ## [3.6] -- 2024-03-14 ### Changed diff --git a/docs/templates/python/nature/attribute.html b/docs/templates/python/nature/attribute.html index 8df5453ff..906d292b7 100644 --- a/docs/templates/python/nature/attribute.html +++ b/docs/templates/python/nature/attribute.html @@ -1,7 +1,7 @@ {% extends "_base/attribute.html" %} {% block heading scoped %} - ‹› + ‹› {% if config.show_symbol_type_heading %}{% endif %} {%+ filter highlight(language="python", inline=True) %} {{ attribute_name }}{% if attribute.annotation %}: {{ attribute.annotation }}{% endif %} diff --git a/docs/templates/python/nature/class.html b/docs/templates/python/nature/class.html index 7193c3419..dc8b58511 100644 --- a/docs/templates/python/nature/class.html +++ b/docs/templates/python/nature/class.html @@ -1,6 +1,6 @@ {% extends "_base/class.html" %} {% block heading scoped %} - ‹› + ‹› {{ super() }} {% endblock heading %} diff --git a/docs/templates/python/nature/function.html b/docs/templates/python/nature/function.html index 82a696a34..9703647e5 100644 --- a/docs/templates/python/nature/function.html +++ b/docs/templates/python/nature/function.html @@ -1,6 +1,6 @@ {% extends "_base/function.html" %} {% block heading scoped %} - ‹› + ‹› {{ super() }} {% endblock heading %} diff --git a/docs/templates/python/nature/module.html b/docs/templates/python/nature/module.html index 4d758a388..0b9b9f099 100644 --- a/docs/templates/python/nature/module.html +++ b/docs/templates/python/nature/module.html @@ -1,6 +1,6 @@ {% extends "_base/module.html" %} {% block heading scoped %} - ‹› + ‹› {{ super() }} {% endblock heading %}