Marco Ricci commited on 2024-11-27 18:21:17
Zeige 7 geänderte Dateien mit 7 Einfügungen und 4 Löschungen.
Symlinks interact very poorly with online git repository viewers, and while they are offline viewable on Unixish systems, readers only see the source view, not the rendered view. For the documentation frontpage `docs/index.md`, use the Snippets extension (Material for MkDocs/Python-Markdownx) to include the contents of `README.md`. This will allow future customization of the frontpage by either appending further content or only embedding parts of the README. For the changelog, because we use `scriv` to maintain it semi-automatically and thus want the changelog snippets to stay out of the top-level directory, we do not want `docs/changelog.md` to symlink to or to snippet-include the top-level `CHANGELOG.md`. Instead, we let `CHANGELOG.md` point to the `docs` directory (in prose), and purge the symlinks to the SVG badges. The original intent was to make the changelog renderable at the top-level, without the MkDocs machinery, but this is only really feasible if the changelog is handwritten, which hasn't been the case anymore for quite some time already.
... | ... |
@@ -0,0 +1 @@ |
1 |
+(See docs/ directory.) |
... | ... |
@@ -0,0 +1 @@ |
1 |
+--8<-- "README.md" |
... | ... |
@@ -125,6 +125,11 @@ markdown_extensions: |
125 | 125 |
- toc: |
126 | 126 |
permalink: true |
127 | 127 |
- pymdownx.details |
128 |
+ - pymdownx.snippets: |
|
129 |
+ base_path: |
|
130 |
+ - 'docs' |
|
131 |
+ - '.' |
|
132 |
+ check_paths: true |
|
128 | 133 |
- pymdownx.superfences |
129 | 134 |
- pymdownx.tabbed: |
130 | 135 |
alternate_style: true |
131 | 136 |