fix: Set curl to silent and fail

This commit is contained in:
Gerald Pinder 2024-09-16 21:32:03 -04:00
parent ee40a8105d
commit 12135f7c9c
6 changed files with 35 additions and 17 deletions

View file

@ -75,7 +75,8 @@ touch /.dockerenv
# Always install Brew
echo "Downloading and installing Brew..."
curl -Lo /tmp/brew-install https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh
curl -sfLo /tmp/brew-install https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh
echo "Downloaded Brew install script"
chmod +x /tmp/brew-install
/tmp/brew-install
@ -193,8 +194,10 @@ if [[ ! -d "/etc/profile.d/" ]]; then
fi
if [[ ! -f "/etc/profile.d/brew.sh" ]]; then
echo "Apply brew path export fix, to solve path conflicts between system & brew programs with same name"
echo "#!/usr/bin/env bash
[[ -d /home/linuxbrew/.linuxbrew && $- == *i* ]] && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"" > "/etc/profile.d/brew.sh"
cat > /etc/profile.d/brew.sh <<EOF
#!/usr/bin/env bash
[[ -d /home/linuxbrew/.linuxbrew && $- == *i* ]] && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
EOF
fi
# Copy shell configuration files
@ -234,7 +237,7 @@ fi
# Apply nofile limits if enabled
if [[ "${NOFILE_LIMITS}" == true ]]; then
source "${MODULE_DIRECTORY}"/brew/brew-nofile-limits-logic.sh
source "${MODULE_DIRECTORY}/brew/brew-nofile-limits-logic.sh"
fi
# Disable homebrew analytics if the flag is set to false