Skip to content

Commit

Permalink
add conditional for package installation
Browse files Browse the repository at this point in the history
Signed-off-by: FaithKovi <[email protected]>
  • Loading branch information
FaithKovi committed Sep 29, 2023
1 parent 8727b35 commit eb02640
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,16 @@ while true; do
break

elif [[ $system == "CYGWIN" || "$(uname)" == * ]]; then
choco install -y git gh curl nodejs
fi
packages=("git" "gh" "curl" "nodejs")

for package in "${packages[@]}"; do
if ! command -v "$package" &> /dev/null; then
echo "Installing $package..."
choco install -y "$package"
else
echo "$package is already installed."
fi
done
done
echo
#Configures git
Expand Down

0 comments on commit eb02640

Please sign in to comment.