From 44a98fb20c31f7ec425f67f48fd1fb2f4f831c81 Mon Sep 17 00:00:00 2001 From: Aravinth Manivannan Date: Fri, 28 Oct 2022 14:30:12 +0530 Subject: [PATCH] fix: links rendered from letter.md should point to root DESCRIPTION README.md is processed and written to content/letter.md before invoking Zola. templates/index.html uses a hack to render content/letter.md in index.html. So relative links defined in letter.md, will be relative to /letter/ This patch removes /letter/ from links --- scripts/zola.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/zola.sh b/scripts/zola.sh index 7d5cd09..e48bf70 100755 --- a/scripts/zola.sh +++ b/scripts/zola.sh @@ -80,6 +80,7 @@ build() { } no_absolute_url() { + sed -i 's/https:\/\/gitea-open-letter.coding.social\/letter\//https:\/\/gitea-open-letter.coding.social\//g' $(find public -type f | grep html) sed -i 's/https:\/\/gitea-open-letter.coding.social//g' $(find public -type f | grep html) }