diff --git a/.gitea/workflows/build-and-push.yml b/.gitea/workflows/build-and-push.yml index 303ef2f..4999be6 100644 --- a/.gitea/workflows/build-and-push.yml +++ b/.gitea/workflows/build-and-push.yml @@ -24,10 +24,10 @@ jobs: uses: actions/checkout@v4 - name: Set image tags id: vars - shell: bash + shell: sh run: | - SHORT_SHA="${GITHUB_SHA::7}" - BRANCH="${GITHUB_REF_NAME//\//-}" + SHORT_SHA=$(printf '%s' "$GITHUB_SHA" | cut -c1-7) + BRANCH=$(printf '%s' "$GITHUB_REF_NAME" | tr '/' '-') echo "short_sha=${SHORT_SHA}" >> "$GITHUB_OUTPUT" echo "branch=${BRANCH}" >> "$GITHUB_OUTPUT"