mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Use Bash arrays for variables containing multiple space-separated values
This commit is contained in:
+7
-7
@@ -4,8 +4,8 @@ set -e
|
||||
REPO_ROOT="$(dirname "$0")"/..
|
||||
USE_DEBUGGER=0
|
||||
DEBUGGER="gdb --args"
|
||||
BOOST_OPTIONS=
|
||||
SOLTEST_OPTIONS=
|
||||
BOOST_OPTIONS=()
|
||||
SOLTEST_OPTIONS=()
|
||||
SOLIDITY_BUILD_DIR=${SOLIDITY_BUILD_DIR:-${REPO_ROOT}/build}
|
||||
|
||||
usage() {
|
||||
@@ -41,7 +41,7 @@ do
|
||||
;;
|
||||
--boost-options)
|
||||
shift
|
||||
BOOST_OPTIONS="${BOOST_OPTIONS} $1"
|
||||
BOOST_OPTIONS+=("$1")
|
||||
;;
|
||||
--help)
|
||||
usage
|
||||
@@ -49,13 +49,13 @@ do
|
||||
;;
|
||||
--run_test | -t )
|
||||
shift
|
||||
BOOST_OPTIONS="${BOOST_OPTIONS} -t $1"
|
||||
BOOST_OPTIONS+=(-t "$1")
|
||||
;;
|
||||
--show-progress | -p)
|
||||
BOOST_OPTIONS="${BOOST_OPTIONS} $1"
|
||||
BOOST_OPTIONS+=("$1")
|
||||
;;
|
||||
*)
|
||||
SOLTEST_OPTIONS="${SOLTEST_OPTIONS} $1"
|
||||
SOLTEST_OPTIONS+=("$1")
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
@@ -64,4 +64,4 @@ if [ "$USE_DEBUGGER" -ne "0" ]; then
|
||||
DEBUG_PREFIX=${DEBUGGER}
|
||||
fi
|
||||
|
||||
exec ${DEBUG_PREFIX} "${SOLIDITY_BUILD_DIR}/test/soltest" ${BOOST_OPTIONS} -- --testpath "${REPO_ROOT}/test" ${SOLTEST_OPTIONS}
|
||||
exec ${DEBUG_PREFIX} "${SOLIDITY_BUILD_DIR}/test/soltest" "${BOOST_OPTIONS[@]}" -- --testpath "${REPO_ROOT}/test" "${SOLTEST_OPTIONS[@]}"
|
||||
|
||||
Reference in New Issue
Block a user