From c348cc8cc76306c3d3e533888b3d30ea7566e075 Mon Sep 17 00:00:00 2001 From: Volpeon Date: Mon, 21 Dec 2020 19:57:20 +0100 Subject: Use Pandoc to write content in Markdown --- build.sh | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) (limited to 'build.sh') diff --git a/build.sh b/build.sh index 3746369..bc733cc 100755 --- a/build.sh +++ b/build.sh @@ -1,15 +1,25 @@ #!/bin/bash -sassc --style expanded src/style.scss dist/style.css +SITE_TITLE="Volpeon's Den" -pyftsubset src/iosevka-term-ss09-regular.ttf \ - --text-file='src/glyphs.txt' \ - --layout-features+=ss09,PURS \ +rm -rf dist/* + +sassc assets/style.scss dist/style.css +node_modules/.bin/postcss dist/style.css -r + +pyftsubset assets/iosevka-term-ss09-regular.ttf \ + --text-file='assets/glyphs.txt' \ + --layout-features+=ss09,dlig \ --flavor='woff2' \ --output-file='dist/iosevka-term-ss09-regular.woff2' -pyftsubset src/iosevka-term-ss09-bold.ttf \ - --text-file='src/glyphs.txt' \ - --layout-features+=ss09,PURS \ +pyftsubset assets/iosevka-term-ss09-bold.ttf \ + --text-file='assets/glyphs.txt' \ + --layout-features+=ss09,dlig \ --flavor='woff2' \ --output-file='dist/iosevka-term-ss09-bold.woff2' + +find content/ \ + -iname "*.md" \ + -type f \ + -exec sh -c 'TARGET=dist/$(echo ${0%.md}.html | cut -sd / -f 2-); mkdir -p $(dirname $TARGET) && pandoc "${0}" -t html5 --template templates/base.html -o "$TARGET" --metadata sitetitle="$1"' {} "$SITE_TITLE" \; -- cgit v1.2.3-54-g00ecf