summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2019-02-28 20:04:27 +0000
committerEdward Thomson <ethomson@edwardthomson.com>2019-02-28 21:34:02 +0000
commite66f2632c7cf02c9bcbcfddc738714d25a67b62f (patch)
tree5d051ac0288a9485bf0ca2081252b694dc72702a
parentc7e5eca6a300138121d844908faec44a12ddc307 (diff)
downloadlibgit2-ethomson/remove_bashisms.tar.gz
ci: use sh not bashethomson/remove_bashisms
There's nothing bash-y about our build and test scripts. Use sh instead of bash for bash-deprived systems like FreeBSD.
-rwxr-xr-xci/build.sh4
-rwxr-xr-xci/test.sh4
2 files changed, 4 insertions, 4 deletions
diff --git a/ci/build.sh b/ci/build.sh
index 7ffa610ae..c2dca6cd1 100755
--- a/ci/build.sh
+++ b/ci/build.sh
@@ -1,4 +1,4 @@
-#!/usr/bin/env bash
+#!/usr/bin/env sh
#
# Environment variables:
#
@@ -7,7 +7,7 @@
set -e
-SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname "${BASH_SOURCE[0]}" )" && dirname $( pwd ) )}
+SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname -- "${BASH_SOURCE[0]:-0}" )" && dirname $( pwd ) )}
BUILD_DIR=$(pwd)
CC=${CC:-cc}
diff --git a/ci/test.sh b/ci/test.sh
index 136ff2581..91781a43d 100755
--- a/ci/test.sh
+++ b/ci/test.sh
@@ -1,4 +1,4 @@
-#!/usr/bin/env bash
+#!/usr/bin/env sh
set -e
@@ -6,7 +6,7 @@ if [ -n "$SKIP_TESTS" ]; then
exit 0
fi
-SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname "${BASH_SOURCE[0]}" )" && dirname $( pwd ) )}
+SOURCE_DIR=${SOURCE_DIR:-$( cd "$( dirname -- "${BASH_SOURCE[0]:-0}" )" && dirname $( pwd ) )}
BUILD_DIR=$(pwd)
TMPDIR=${TMPDIR:-/tmp}
USER=${USER:-$(whoami)}