aboutsummaryrefslogblamecommitdiff
path: root/aux/workflow/commonmark.sh
blob: 6016f51b4ecce64d8608d6f3ea6028e26a0da86a (plain) (tree)
1
2
3
4
5
6
7
8
9






               
                        
 










                                                  
#!/bin/sh
set -eu

mkdir -p public

PROJECT_UC="$1"
F="$2"
OUT="${3:-${F%.*}.html}"

pandoc \
	--toc                                    \
	--highlight-style pygments               \
	--toc-depth=2                            \
	-s                                       \
	--metadata title="$PROJECT_UC - ${F%.*}" \
	--metadata lang=en                       \
	-r commonmark                            \
	-w html                                  \
	-H aux/workflow/favicon.html             \
	< "$F" > "public/$OUT"