diff --git a/scripts/common_cmdline.sh b/scripts/common_cmdline.sh index 5263b6121..2637fdedb 100644 --- a/scripts/common_cmdline.sh +++ b/scripts/common_cmdline.sh @@ -51,12 +51,12 @@ function compileFull() local files=("$@") - local stderr_path=$(mktemp) + local stderr_path; stderr_path=$(mktemp) set +e "$SOLC" "${args[@]}" "${files[@]}" >/dev/null 2>"$stderr_path" local exit_code=$? - local errors=$(grep -v -E 'Warning: This is a pre-release compiler version|Warning: Experimental features are turned on|pragma experimental ABIEncoderV2|^ +--> |^ +\||^[0-9]+ +\|' < "$stderr_path") + local errors; errors=$(grep -v -E 'Warning: This is a pre-release compiler version|Warning: Experimental features are turned on|pragma experimental ABIEncoderV2|^ +--> |^ +\||^[0-9]+ +\|' < "$stderr_path") set -e rm "$stderr_path" diff --git a/scripts/wasm-rebuild/docker-scripts/rebuild_tags.sh b/scripts/wasm-rebuild/docker-scripts/rebuild_tags.sh index 3475057e4..05ada07f3 100755 --- a/scripts/wasm-rebuild/docker-scripts/rebuild_tags.sh +++ b/scripts/wasm-rebuild/docker-scripts/rebuild_tags.sh @@ -86,7 +86,7 @@ function process_tag() { local TAG=$1 cd /src # Checkout the historic commit instead of the tag directly. - local HISTORIC_COMMIT_HASH="$(grep "${TAG}+" /tmp/release_commit_list.txt | cut -d '+' -f 2 | cut -d '.' -f 2)" + local HISTORIC_COMMIT_HASH; HISTORIC_COMMIT_HASH="$(grep "${TAG}+" /tmp/release_commit_list.txt | cut -d '+' -f 2 | cut -d '.' -f 2)" if [ "$(git cat-file -t "${HISTORIC_COMMIT_HASH}" 2>/dev/null)" == "commit" ]; then clean_git_checkout "$HISTORIC_COMMIT_HASH" else @@ -103,7 +103,7 @@ function process_tag() { VERSION=$(echo "$TAG" | cut -d v -f 2) fi - local COMMIT_HASH=$(git rev-parse --short=8 HEAD) + local COMMIT_HASH; COMMIT_HASH=$(git rev-parse --short=8 HEAD) local FULL_VERSION_SUFFIX="${TAG}+commit.${COMMIT_HASH}" local HISTORIC_VERSION_SUFFIX="${TAG}+commit.${HISTORIC_COMMIT_HASH}" diff --git a/test/cmdlineTests.sh b/test/cmdlineTests.sh index b86561f71..16b5b5df6 100755 --- a/test/cmdlineTests.sh +++ b/test/cmdlineTests.sh @@ -121,8 +121,8 @@ function test_solc_behaviour() local stderr_expected="${7}" local stdout_expectation_file="${8}" # the file to write to when user chooses to update stdout expectation local stderr_expectation_file="${9}" # the file to write to when user chooses to update stderr expectation - local stdout_path=$(mktemp) - local stderr_path=$(mktemp) + local stdout_path; stdout_path=$(mktemp) + local stderr_path; stderr_path=$(mktemp) trap "rm -f $stdout_path $stderr_path" EXIT