commit | author | age | ||
918492 | 1 | REPO_DIR=$HOME/sites |
JG | 2 | SITE_DIR=repo |
3 | DEPLOY_DIR=/Eduardo/repo | |
4 | ||
5 | cd $REPO_DIR/$SITE_DIR | |
6 | ||
7 | # Check for repo update | |
8 | if [[ -n $(git pull | grep 'Already up to date.') ]]; then | |
9 | # exit | |
10 | echo 1 | |
11 | fi | |
12 | ||
13 | # Build site | |
14 | hugo | |
15 | ||
16 | # sync new files across | |
17 | rsync -av public/* $DEPLOY_DIR/ | |
18 |