#!/bin/sh # This is an automated deployment script for use in Ayllu from which this # website is hosted. set -x GENERATED_BRANCH="generated" if git status --porcelain | grep -q .; then echo "repository dirty, aborting" exit 1 fi if [ "$(git rev-parse --abbrev-ref HEAD)" -ne "main" ]; then echo "repository needs to be on the main branch" exit 1 fi git checkout "$GENERATED_BRANCH" -- git reset --hard main git clean -fd zola build git add -f public git commit -m 'automated www update' git checkout main