gmgauthier.com/publish.sh

17 lines
488 B
Bash
Executable File

#!/usr/bin/env sh
# commit and push...
git add .;git commit -m"$@";git push -u origin master
# build the site
hugo
# push the files to the webserver
# scp -rp * root@boethius:/hosting/sites/gmgauthier.com
rsync -avh -e ssh ./public/* root@boethius:/hosting/sites/gmgauthier.com
echo "chown -R www-data:www-data /hosting/sites/gmgauthier.com" | ssh root@boethius /bin/bash
echo "ls -lA /hosting/sites/gmgauthier.com" | ssh root@boethius /bin/bash
# remove the old build
# rm -R public