#!/usr/bin/env bash

find . -name .DS_Store -delete

echo
echo "> Deploying static site to Hetzner..."
echo 

pnpm run build || exit 1

rsync -avz \
    -e "ssh -i $HOME/.ssh/hetzner_first" \
    --delete \
    dist/ \
    root@vojtechstruhar.com:/var/www/fimuni-mgr-notes

rm -rf dist

echo
echo "Done"
