homepage/deploy
surtur 3af0a7366e
All checks were successful
continuous-integration/drone/push Build is passing
feat: added bin to $PATH + moved version check to gethugo
2020-06-03 12:46:10 +02:00

25 lines
356 B
Bash
Executable File

#!/bin/bash
USR=dotyaoverlord
HOST=dotya.ml
DIR=public/
export HUGO_VERSION=$1
PATH=~/.local/bin:$PATH
gethugo $HUGO_VERSION
git submodule init
git submodule update
which hugo
hugo version
hugo --gc=true --minify
if [ $USER = $USR ]; then
rsync -av --delete public/ ~/${DIR}
else
rsync -avz --delete public/ ${USR}@${HOST}:~/${DIR}
fi
exit 0