fix(ci): respect rc pattern

This commit is contained in:
2026-06-01 22:35:55 +02:00
parent 2237090669
commit b6cef2159e
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
#!/bin/bash
set -e
set -eo pipefail
CHART_FILE="Chart.yaml"
if [ ! -f "${CHART_FILE}" ]; then
+3 -2
View File
@@ -71,8 +71,9 @@ jobs:
- name: Add Artifacthub.io annotations
run: |
NEW_TAG="$(git tag --sort=-version:refname | head -n 1)"
OLD_TAG="$(git tag --sort=-version:refname | head -n 2 | tail -n 1)"
rc_pattern="\-rc([-\.][0-9]+)?$"
NEW_TAG="$(git tag --sort=-version:refname | grep --invert-match --perl-regexp "${rc_pattern}" | head --lines 1)"
OLD_TAG="$(git tag --sort=-version:refname | grep --invert-match --perl-regexp "${rc_pattern}" | head --lines 2 | tail --lines 1)"
.gitea/scripts/add-annotations.sh "${OLD_TAG}" "${NEW_TAG}"
- name: Extract meta information