7 ms·
mine is: find . -name '*.md' -type f -exec sh -c ' for file do out="docs/${file#./}" out="${out%.md}.html" mkdir -p "$(dirname "$out")"
by malkosta 3mo ago
mine is:
find . -name '*.md' -type f -exec sh -c '
for file do
out="docs/${file#./}"
out="${out%.md}.html"
mkdir -p "$(dirname "$out")"
pandoc --quiet --template template.html "$file" -o "$out"
done
' sh {} +
- packetlost 3mo agoThe only issue is pandoc is a pretty heavy dep. A fantastic tool, but a very heavy one.
- malkosta 3mo agoyes true, but I already have it on all my machines, for diverse reasons...it wouldn't be hard to implement a markdown support, but it would be worse to maintain that