FEATURE: improve little bit update script

This commit is contained in:
Michal Kváček
2017-02-11 01:24:28 +01:00
parent 2fdec0a65f
commit 0ae3e4fe08
+15 -4
View File
@@ -31,6 +31,14 @@ if [ ! $? -eq 0 ]; then
fi
git checkout $BRANCH
if [ ! $? -eq 0 ]; then
echo " *****************************************"
echo " * ERROR: cannot do git checkout $BRANCH *"
echo " *****************************************"
exit 2
fi
git pull origin $BRANCH
if [ ! $? -eq 0 ]; then
@@ -40,14 +48,18 @@ if [ ! $? -eq 0 ]; then
exit 2
fi
set -e
composer install --no-dev
npm install
bower install
php artisan migrate --force -n
php artisan module:migrate --force -n
php artisan vendor:publish --tag=module-views --force -n
php artisan vendor:publish --tag=public-assets --force -n
php artisan vendor:publish
php artisan template:publish
php artisan clear-compiled
php artisan view:clear
php artisan optimize
# this part need running as root
sudo chmod 0777 bootstrap/cache -R
@@ -59,8 +71,7 @@ sudo chmod 0777 modules/*/module.json
sudo chmod 0777 modules/*/*/module.json
sudo chmod +x scripts/*
npm install
gulp --production
php artisan up
set +e