Skip to content
Snippets Groups Projects
Commit f42180c4 authored by jurgenhaas's avatar jurgenhaas
Browse files

Allow to force execution of update script

parent 7bc59d12
Branches
No related tags found
No related merge requests found
#!/usr/bin/env bash
force=0
if [ "$1" = "--force" ]; then
force=1
fi;
echo '>> {{ apacheUser }}'
date
{% set path=[webRoot, drupal.src.git.target2|default(drupal.src.git.target)]|join('') %}
cd {{ path }}
echo '> check for changes'
OUTPUT=$(git remote show origin)
if [[ $OUTPUT == *"master pushes to master (up to date)"* ]]; then
echo "> unchanged, cancel"
exit
if [ $force -eq 0 ]; then
echo '> check for changes'
OUTPUT=$(git remote show origin)
if [[ $OUTPUT == *"master pushes to master (up to date)"* ]]; then
echo "> unchanged, cancel"
exit
fi
fi
LOCKFILE={{ webRoot }}/.update.lock
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment