#!/usr/bin/env bash ## # This section should match your Makefile ## PY=${PY:-python} PELICAN=${PELICAN:-pelican} PELICANOPTS= BASEDIR=$(pwd) INPUTDIR=$BASEDIR/content OUTPUTDIR=$BASEDIR/output CONFFILE=$BASEDIR/pelicanconf.py ### # Don't change stuff below here unless you are sure ### SRV_PID=$BASEDIR/srv.pid PELICAN_PID=$BASEDIR/pelican.pid function usage(){ echo "usage: $0" echo "This compiles the pelican site in the current directory," echo "using ./pelicanconf.py as configuration file," echo " ./content as input directory," echo " ./output as output directory (overwriting it)." exit 3 } function compile(){ echo "Compiling" shift rm -r $OUTPUTDIR $PELICAN $INPUTDIR -o $OUTPUTDIR -s $CONFFILE $PELICANOPTS } ### # MAIN ### if [[ $1 == "help" ]]; then usage else compile fi