Skip to content

Commit ad480c1

Browse files
committed
fix patch file
1 parent 3a63194 commit ad480c1

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

offline/tasks/patch-chart-images.sh

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,7 @@ echo "Scanning and patching files..."
112112
# Process values.yaml files
113113
while IFS= read -r -d '' file; do
114114
file_count=$((file_count + 1))
115-
patch_file "$file"
116-
rc=$?
115+
patch_file "$file" && rc=$? || rc=$?
117116
if [[ $rc -eq 0 ]]; then
118117
patched_count=$((patched_count + 1))
119118
elif [[ $rc -eq 2 ]]; then
@@ -124,8 +123,7 @@ done < <(find "$CHARTS_DIR" -name "values.yaml" -print0)
124123
# Process Chart.yaml files
125124
while IFS= read -r -d '' file; do
126125
file_count=$((file_count + 1))
127-
patch_file "$file"
128-
rc=$?
126+
patch_file "$file" && rc=$? || rc=$?
129127
if [[ $rc -eq 0 ]]; then
130128
patched_count=$((patched_count + 1))
131129
elif [[ $rc -eq 2 ]]; then
@@ -136,8 +134,7 @@ done < <(find "$CHARTS_DIR" -name "Chart.yaml" -print0)
136134
# Process template files (for direct image references)
137135
while IFS= read -r -d '' file; do
138136
file_count=$((file_count + 1))
139-
patch_file "$file"
140-
rc=$?
137+
patch_file "$file" && rc=$? || rc=$?
141138
if [[ $rc -eq 0 ]]; then
142139
patched_count=$((patched_count + 1))
143140
elif [[ $rc -eq 2 ]]; then

0 commit comments

Comments
 (0)