feat: add notes

This commit is contained in:
2024-09-30 22:26:29 +02:00
parent ae59cb7ed9
commit ba85815b7e
11 changed files with 217 additions and 0 deletions

18
notes/make-views.sh Executable file
View File

@@ -0,0 +1,18 @@
#!/usr/bin/env bash
set -e;
MYSELF=$(realpath "$0");
MYDIR=$(dirname "$MYSELF");
PRE_IMPORT=${PRE_IMPORT:-/components/md-pre.html}
POST_IMPORT=${POST_IMPORT:-/components/md-post.html}
find "${1-$MYDIR}" -iname '*.md' | while read -r line; do
# target=${line//\.md/.html}
target=$(sed 's/\.md$/\.html/' <<< "$line")
echo "$line -> $target";
echo "<!--# include virtual=\"$PRE_IMPORT\" -->" > "$target"
pandoc --mathml "$line" -o - >> "$target"
echo "<!--# include virtual=\"$POST_IMPORT\" -->" >> "$target"
done