#!/bin/sh mkdir -p dest cp logo-* style.css dest cat _index_header.html > dest/index.html for f in $(find itemy -name '*.md'); do file=$(basename $f .md) title=$(grep '^# ' $f | head -n 1 | cut -c 3-) echo "
  • $title
  • " >> dest/index.html cat _header.html > dest/$file.html sed 's/^# \(.*\)/

    \1<\/h2>/' $f >> dest/$file.html echo " " >> dest/$file.html done echo " " >> dest/index.html