From 742f9de34b92639b159c975d50b071917a933389 Mon Sep 17 00:00:00 2001 From: hayao Date: Fri, 9 Apr 2021 20:54:16 +0900 Subject: [PATCH] [update] : Array _options --- tools/fullbuild.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/fullbuild.sh b/tools/fullbuild.sh index 8af5a985..7c7152cf 100755 --- a/tools/fullbuild.sh +++ b/tools/fullbuild.sh @@ -83,9 +83,9 @@ trap_exit() { build() { - local _exit_code=0 + local _exit_code=0 _options=("${share_options[@]}") - options="${share_options[*]} --arch ${arch} --lang ${lang} ${cha}" + _options+=("--arch" "${arch}" "--lang" "${lang}" "--" "${cha}") if [[ "${simulation}" = false ]] && [[ "${remove_cache}" = true ]]; then sudo pacman -Sccc --noconfirm @@ -93,11 +93,11 @@ build() { if [[ ! -e "${fullbuild_dir}/fullbuild.${cha}_${arch}_${lang}" ]]; then if [[ "${simulation}" = true ]]; then - echo "build.sh ${options}" + echo "sudo bash build.sh ${_options[*]}" _exit_code="${?}" else msg_info "Build the ${lang} version of ${cha} on the ${arch} architecture." - sudo bash ${script_path}/build.sh ${options} + eval sudo bash "${script_path}/build.sh" "${_options[@]}" _exit_code="${?}" if [[ "${_exit_code}" = 0 ]]; then touch "${fullbuild_dir}/fullbuild.${cha}_${arch}_${lang}" -- 2.11.0