Skip to content

Commit

Permalink
fix: No update prompt if the target folder contains an unconfigured H…
Browse files Browse the repository at this point in the history
…igress instance (higress-group#42)
  • Loading branch information
CH3CHO authored Oct 16, 2023
1 parent 010256d commit a8509e3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/get-higress.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ parseArgs() {

validateArgs() {
if [ -d "$DESTINATION" ]; then
if [ "$(ls -A "$DESTINATION")" -a "$MODE" != "update" ]; then
echo "The target folder \"$DESTINATION\" is not empty. Add \"-u\" to update an existed Higress instance." && exit 1
if [ -e "${DESTINATION}/compose/.configured" -a "$MODE" != "update" ]; then
echo "Higress is already installed in the target folder \"$DESTINATION\". Add \"-u\" to update an existed Higress instance." && exit 1
fi
if [ ! -w "$DESTINATION" ]; then
echo "The target folder \"$DESTINATION\" is not writeable." && exit 1
Expand Down

0 comments on commit a8509e3

Please sign in to comment.