#!/bin/bash # compiles new post into target directory rootDir='./tmp/' post() { # First get the body of the document tmp=".swap" base=$(basename $1) cat 'templates/post-header.html' > $tmp pandoc $1 >> $tmp cat 'templates/post-footer.html' >> $tmp sed -i "3i