From b951ff36b4ba771d01ff077b78e73df5e930de48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Soko=C5=82owski?= Date: Mon, 10 Jan 2022 16:21:47 +0100 Subject: [PATCH] nix: fix setup.sh script when running on MacOS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jakub SokoĊ‚owski --- nix/scripts/setup.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nix/scripts/setup.sh b/nix/scripts/setup.sh index e0687e65e4e..cc747b36f19 100755 --- a/nix/scripts/setup.sh +++ b/nix/scripts/setup.sh @@ -28,12 +28,12 @@ function install_nix() { fi } -if [[ ! -x "$(command -v git)" ]]; then +if [[ ! -x "$(command -v curl)" ]]; then echo -e "${RED}The 'curl' utility is required for Nix installation.${RST}" >&2 exit 1 fi -if [[ "$(source /etc/os-release && echo "${NAME}")" == *NixOS* ]]; then +if [[ "$(source /etc/os-release 2>/dev/null && echo "${NAME}")" == *NixOS* ]]; then echo -e "${GRN}Already running NixOS.${RST}" exit fi