From 360601e26257e94c5641b434fecf77674cf5feef Mon Sep 17 00:00:00 2001 From: ZDDC Date: Mon, 4 May 2026 07:46:01 -0500 Subject: [PATCH] fix(ci): chart MINOR-bump on stable cut (resets PATCH to 0) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Chart version was monotonically incrementing PATCH on every chart-bump — after ~50 betas + a few stable cuts, version was already at 0.2.12. Triple digits would land within a year of active dev. Switch the stable-cut branch of notify-chart-bump.sh to bump MINOR and reset PATCH to 0: stable: 0.2.X → 0.3.0 beta: 0.3.0 → 0.3.1, 0.3.1 → 0.3.2, ... next stable: 0.3.X → 0.4.0 Patches stay bounded (≈ betas-per-stable, not all-time). MINOR keeps incrementing so JFrog chart-repo uploads stay accepted (it rejects duplicate chart-version numbers — a literal "reset to 0.2.0" cycle would break uploads on the second stable cut). Chart version is purely JFrog packaging metadata; the zddc-server version users actually care about lives in appVersion. --- .forgejo/scripts/notify-chart-bump.sh | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/.forgejo/scripts/notify-chart-bump.sh b/.forgejo/scripts/notify-chart-bump.sh index 863d1b6..b9a34ce 100755 --- a/.forgejo/scripts/notify-chart-bump.sh +++ b/.forgejo/scripts/notify-chart-bump.sh @@ -129,7 +129,20 @@ for BRANCH in $BRANCHES; do MAJC=$(echo "$OLD_CHART_VER" | cut -d. -f1) MINC=$(echo "$OLD_CHART_VER" | cut -d. -f2) PATC=$(echo "$OLD_CHART_VER" | cut -d. -f3) - NEW_CHART_VER="$MAJC.$MINC.$((PATC + 1))" + # Chart-version bump strategy: + # stable cut → MINOR++, PATCH=0 (e.g. 0.2.7 → 0.3.0) + # beta cut → PATCH++ (e.g. 0.3.0 → 0.3.1) + # This keeps the patch number bounded (≈ #betas-per-stable, not + # all-time), while staying monotonically increasing — JFrog chart + # repos reject duplicate chart-version numbers, so a literal + # "reset to 0.2.0" cycle would break uploads after the first + # stable cut. The actual zddc-server version lives in appVersion; + # chart version is just JFrog packaging metadata. + if [ "$CHANNEL" = "stable" ]; then + NEW_CHART_VER="$MAJC.$((MINC + 1)).0" + else + NEW_CHART_VER="$MAJC.$MINC.$((PATC + 1))" + fi sed -i "s/^version: .*/version: $NEW_CHART_VER/" chart/Chart.yaml echo " appVersion: $CURRENT → $TARGET_VERSION"