From 21a5164e1231976ff8101eb79282e68e5f42579f Mon Sep 17 00:00:00 2001 From: zimbatm Date: Wed, 17 Nov 2021 23:02:06 +0100 Subject: [PATCH] install-nix.sh: fix shellcheck issues --- lib/install-nix.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/install-nix.sh b/lib/install-nix.sh index d884fd3..ea783dd 100755 --- a/lib/install-nix.sh +++ b/lib/install-nix.sh @@ -37,7 +37,7 @@ installer_options=( if [[ $OSTYPE =~ darwin || -e /run/systemd/system ]]; then installer_options+=( --daemon - --daemon-user-count `python -c 'import multiprocessing as mp; print(mp.cpu_count() * 2)'` + --daemon-user-count "$(python -c 'import multiprocessing as mp; print(mp.cpu_count() * 2)')" ) else # "fix" the following error when running nix* @@ -46,11 +46,11 @@ else fi if [[ $INPUT_INSTALL_OPTIONS != "" ]]; then - IFS=' ' read -r -a extra_installer_options <<< $INPUT_INSTALL_OPTIONS + IFS=' ' read -r -a extra_installer_options <<< "$INPUT_INSTALL_OPTIONS" installer_options=("${extra_installer_options[@]}" "${installer_options[@]}") fi -echo "installer options: ${installer_options[@]}" +echo "installer options: ${installer_options[*]}" # There is --retry-on-errors, but only newer curl versions support that until curl -o "$workdir/install" -v --fail --retry 5 --retry-connrefused -L "${INPUT_INSTALL_URL:-https://nixos.org/nix/install}"