From 2e68c0bba791fab3c544d6bc6c3c5bd2e33b1ba4 Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Thu, 7 Apr 2022 13:48:38 -0700 Subject: [PATCH] Add .. link. --- voussoir.net/writing/vmarkdown.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/voussoir.net/writing/vmarkdown.py b/voussoir.net/writing/vmarkdown.py index f36aef5..99b1778 100644 --- a/voussoir.net/writing/vmarkdown.py +++ b/voussoir.net/writing/vmarkdown.py @@ -740,6 +740,9 @@ def markdown_flask(core_filename, port, *args, **kwargs): if path.is_dir: atags = [] + if path in cwd: + parent = path.parent.relative_to(cwd, simple=True) + atags.append(f'..') children = sorted(path.listdir(), key=lambda p: (p.is_file, p.basename.lower())) for child in children: relative = child.relative_to(cwd, simple=True)