csb-init
Raw
#!/bin/bash
set -euo pipefail
HELP="Initialize a new csb site
Usage:
$(basename ${0})
$(basename ${0}) (-h|--help)
Options:
-h, --help Show this message and exit"
args=$(echo "$HELP" | csb-optparse "$@")
trap "rm -rf $args" EXIT
[[ $(< "${args}/--help") == "true" ]] && echo "$HELP" && exit 0
TARGET="$PWD"
TYPE=multi
STATICDIR=static
CONTENTDIR=content
TEMPLATEDIR=templates
csb-new "$TARGET" "$TYPE" --static "$STATICDIR" --templates "$TEMPLATEDIR" --content "$CONTENTDIR"
csb-templates "$TARGET/$TEMPLATEDIR"