Don't deploy when on branches other than master
This commit is contained in:
parent
ecdffa8ec5
commit
ae506afc7b
|
@ -3,6 +3,11 @@
|
||||||
source=public/
|
source=public/
|
||||||
target=apps@spock.ariejan.net:/home/apps/sites/ariejan.net
|
target=apps@spock.ariejan.net:/home/apps/sites/ariejan.net
|
||||||
|
|
||||||
|
if [ ! `git symbolic-ref HEAD | grep -q "refs/heads/master"` ] ; then
|
||||||
|
echo "You are not on the 'master' branch. Not deploying."
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
if [ -d ./public ] ; then
|
if [ -d ./public ] ; then
|
||||||
echo "-- Pruning current static files from ./${source}"
|
echo "-- Pruning current static files from ./${source}"
|
||||||
rm -rf ./${source}
|
rm -rf ./${source}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user