From b7418dc8c9da5791acfd81f691833d23b678736c Mon Sep 17 00:00:00 2001 From: James Lamb Date: Fri, 29 Sep 2023 11:00:25 -0500 Subject: [PATCH] [ci] fix sh-compatibility issue in build-cran-package.sh (#6118) --- build-cran-package.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-cran-package.sh b/build-cran-package.sh index 6558afcf77ad..1c8a5dfbdc48 100755 --- a/build-cran-package.sh +++ b/build-cran-package.sh @@ -132,7 +132,7 @@ cd "${TEMP_R_DIR}" using_windows_and_r3=$( Rscript -e 'cat(.Platform$OS.type == "windows" && R.version[["major"]] < 4)' ) - if [[ ${using_windows_and_r3} == "TRUE" ]]; then + if test "${using_windows_and_r3}" = "TRUE"; then LGB_CXX_STD="C++11" fi sed -i.bak -e "s/~~CXXSTD~~/${LGB_CXX_STD}/" DESCRIPTION