]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
Properly source require.sh 3860/head
authorMatthias Baur <thats@matthiasbaur.me>
Thu, 17 Jan 2019 19:04:57 +0000 (20:04 +0100)
committerMatthias Baur <m.baur@syseleven.de>
Tue, 12 Mar 2019 14:44:38 +0000 (15:44 +0100)
Fixes #3571.

scripts/dev.sh
scripts/install.sh
scripts/update.sh

index 0703ced1ef9111ef4c08d055db471fb43f50fad3..28453be0d63cadeefbdd0e086e68b7c55bfe810b 100755 (executable)
@@ -3,10 +3,14 @@
 # eg: `sh dev.sh`
 
 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"
 
 $COMPOSER_COMMAND install
 php bin/console wallabag:install
index de1fb8f650b57bf21a1baa67f990ff3f3ae6d6dc..affa715ffb5f802b310cd0878f15ec0be872a662 100755 (executable)
@@ -25,10 +25,14 @@ if [ "$IGNORE_ROOT" -eq 0 ] && [ "$EUID" == "0" ]; then
 fi
 
 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"
 
 TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
 
index e86a76db4729cd722cc26051a6e3a84e69b5f7a1..3ef1043920d3157f76b21f312037047320a91147 100755 (executable)
@@ -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