From 45c66cafe2f986cab6ffaa032129bcaeacf7835a Mon Sep 17 00:00:00 2001 From: Mario Siegenthaler Date: Wed, 6 Sep 2023 10:14:37 +0200 Subject: [PATCH] fix: syntax error --- assets/out | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) diff --git a/assets/out b/assets/out index e7421db..e6cd69e 100755 --- a/assets/out +++ b/assets/out @@ -135,26 +135,22 @@ helm_upgrade() { if [ -n "$values" ]; then for value in $values; do - if [[ "${value:0:10}" == 'secrets://' ]]; then - # helm secrets files -> Leave the schema "secrets://" and append the path afterwards - suffix=${value:10} - filename="secrets://$source/$suffix" - upgrade_args+=("-f" "$filename") - upgrade_diff_args+=("-f" "$filename") - elif [ -f "$source/$value" ]; then - upgrade_args+=("-f" "$source/"$value) - upgrade_diff_args+=("-f" "$source/"$value) - else - if [ "$skip_missing_values" == "true" ]; then - echo "skipping missing values file $source/$value" - else - echo "value file $source/$value not found" - exit 1 - fi - fi - else + if [[ "${value:0:10}" == 'secrets://' ]]; then + # helm secrets files -> Leave the schema "secrets://" and append the path afterwards + suffix=${value:10} + filename="secrets://$source/$suffix" + upgrade_args+=("-f" "$filename") + upgrade_diff_args+=("-f" "$filename") + elif [ -f "$source/$value" ]; then upgrade_args+=("-f" "$source/"$value) upgrade_diff_args+=("-f" "$source/"$value) + else + if [ "$skip_missing_values" == "true" ]; then + echo "skipping missing values file $source/$value" + else + echo "value file $source/$value not found" + exit 1 + fi fi done fi