all repos — gemini-redirect @ e64fbcf1326b7ca8d5bc9150190c15ae6df02481

deploy.sh (view raw)

 1set -e
 2# Forgetting uncomitted files in the working directory has costed me the draft of another blog post :)
 3git status | grep "l'albero di lavoro รจ pulito" || (echo "ABORTING DEPLOY, WOULD LOSE FILES"; exit 1)
 4zola build
 5git checkout gh-pages
 6# Forgetting to exclude `.git` has costed me several days worth of work and over 30 commits :)))
 7find . -maxdepth 1 -not -name '.' -not -name '.git' -not -name 'public' -exec rm -r {} \;
 8mv public/* .
 9#echo "birabittoh.dev" > CNAME
10rmdir public/
11git add .
12git commit -m "Deploy site"
13git push
14git checkout master