summaryrefslogtreecommitdiff
path: root/MdToHtml
diff options
context:
space:
mode:
authorJacob McDonnell <jacob@jacobmcdonnell.com>2026-04-08 21:06:31 -0400
committerJacob McDonnell <jacob@jacobmcdonnell.com>2026-04-08 21:06:31 -0400
commitc19dfac86f6b934b0608f8e66e4c0d4c611806e4 (patch)
tree53e2d7ceb01bc73fb91b6f5d0e57fd79efdd991d /MdToHtml
parenta45ec48ef2a48c75d7c20d9c2d20a34de2fe2ba3 (diff)
refactor: Preprocess Markdown Filesv1.1.0
Rather than converting markdown files to html on every request, pre convert them during build of the container.
Diffstat (limited to 'MdToHtml')
-rwxr-xr-xMdToHtml9
1 files changed, 9 insertions, 0 deletions
diff --git a/MdToHtml b/MdToHtml
new file mode 100755
index 0000000..39194af
--- /dev/null
+++ b/MdToHtml
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+
+for FILE in $(find static -type f -name "*.md");
+do
+ echo "Processing $FILE..."
+ pandoc -t html -f markdown "$FILE" > "$(echo "$FILE" | sed 's|\.md$|.html|')"
+ echo "Done"
+done
+