From 7c553a6017c64d98017a6010dc6e77d22ab72da4 Mon Sep 17 00:00:00 2001 From: Matthias Baur Date: Thu, 17 Jan 2019 20:04:57 +0100 Subject: Properly source require.sh Fixes #3571. --- scripts/update.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'scripts/update.sh') diff --git a/scripts/update.sh b/scripts/update.sh index e86a76db..3ef10439 100755 --- a/scripts/update.sh +++ b/scripts/update.sh @@ -28,10 +28,14 @@ set -e set -u COMPOSER_COMMAND='composer' +REQUIRE_FILE='scripts/require.sh' -DIR="${BASH_SOURCE}" -if [ ! -d "$DIR" ]; then DIR="$PWD/scripts"; fi -. "$DIR/require.sh" +if [ ! -f "$REQUIRE_FILE" ]; then + echo "Cannot find $REQUIRE_FILE" + exit 1 +fi + +. "$REQUIRE_FILE" rm -rf var/cache/* git fetch origin -- cgit v1.2.3