From 88e6a293384224ec3f5564d02cbddfe1a8f3b45b Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Tue, 11 Jan 2022 13:59:53 -0800 Subject: [PATCH] Wrap CI script shell variables in quotes to fix local testing. (#10018) This is a tiny PR that wraps shell script variables in quotes. This fixes an issue I saw in the upload script when `${BUILD_MODE}` was not set during local testing of the CI environment. Authors: - Bradley Dice (https://github.com/bdice) Approvers: - Jordan Jacobelli (https://github.com/Ethyling) URL: https://github.com/rapidsai/cudf/pull/10018 --- ci/benchmark/build.sh | 2 +- ci/cpu/upload.sh | 2 +- ci/gpu/build.sh | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ci/benchmark/build.sh b/ci/benchmark/build.sh index 979db1b5034..59bd908d151 100755 --- a/ci/benchmark/build.sh +++ b/ci/benchmark/build.sh @@ -98,7 +98,7 @@ conda list --show-channel-urls ################################################################################ logger "Build libcudf..." -if [[ ${BUILD_MODE} == "pull-request" ]]; then +if [[ "${BUILD_MODE}" == "pull-request" ]]; then "$WORKSPACE/build.sh" clean libcudf cudf dask_cudf benchmarks tests --ptds else "$WORKSPACE/build.sh" clean libcudf cudf dask_cudf benchmarks tests -l --ptds diff --git a/ci/cpu/upload.sh b/ci/cpu/upload.sh index 40e80def8ae..e6ef72d930c 100755 --- a/ci/cpu/upload.sh +++ b/ci/cpu/upload.sh @@ -12,7 +12,7 @@ export GPUCI_RETRY_SLEEP=30 export LABEL_OPTION=${LABEL_OPTION:-"--label main"} # Skip uploads unless BUILD_MODE == "branch" -if [ ${BUILD_MODE} != "branch" ]; then +if [ "${BUILD_MODE}" != "branch" ]; then echo "Skipping upload" return 0 fi diff --git a/ci/gpu/build.sh b/ci/gpu/build.sh index 059e359e4e9..a8afc03af94 100755 --- a/ci/gpu/build.sh +++ b/ci/gpu/build.sh @@ -124,7 +124,7 @@ if [[ -z "$PROJECT_FLASH" || "$PROJECT_FLASH" == "0" ]]; then ################################################################################ gpuci_logger "Build from source" - if [[ ${BUILD_MODE} == "pull-request" ]]; then + if [[ "${BUILD_MODE}" == "pull-request" ]]; then "$WORKSPACE/build.sh" clean libcudf cudf dask_cudf libcudf_kafka cudf_kafka benchmarks tests --ptds else "$WORKSPACE/build.sh" clean libcudf cudf dask_cudf libcudf_kafka cudf_kafka benchmarks tests -l --ptds @@ -222,7 +222,7 @@ else install_dask gpuci_logger "Build python libs from source" - if [[ ${BUILD_MODE} == "pull-request" ]]; then + if [[ "${BUILD_MODE}" == "pull-request" ]]; then "$WORKSPACE/build.sh" cudf dask_cudf cudf_kafka --ptds else "$WORKSPACE/build.sh" cudf dask_cudf cudf_kafka -l --ptds