#!/bin/sh dir=$1 file=$2 page=${file%.create} kind=$(cat "$dir/$file") echo "Creating content/$kind/$page" hugo --source=.. new "content/$kind/$page" # Important to automated tests chmod g+w "../content/$kind/$page"