diff --git a/.gitea/workflows/base-build.yml b/.gitea/workflows/base-build.yml index 7858a7f..2b0aa05 100644 --- a/.gitea/workflows/base-build.yml +++ b/.gitea/workflows/base-build.yml @@ -133,22 +133,18 @@ jobs: git config user.name "${{ env.GIT_USERNAME }}" git config user.email "${{ env.GIT_EMAIL }}" - VERSION=${{ matrix.version }} - - # Create temporary branch for this version - TEMP_BRANCH="tmp-update-${VERSION}-$(date -u +%s)" + TEMP_BRANCH="tmp-update-${{ matrix.version }}-$(date -u +%s)" git checkout -b "$TEMP_BRANCH" - # Stage changes: tarball + version-specific SHA file git add "$VERSION/debian-$VERSION.tar.bz2" "$VERSION/sha256sums.txt" if git diff --cached --quiet; then - echo "[INFO] No changes to commit for $VERSION" + echo "[INFO] No changes to commit for ${{ matrix.version }}" echo "archives_changed=false" >> $GITEA_OUTPUT exit 0 fi - git commit -m "Update base image and checksum for $VERSION on $(date -u +'%Y-%m-%dT%H:%M:%SZ') [skip ci]" + git commit -m "Update base image and checksum for ${{ matrix.version }} on $(date -u +'%Y-%m-%dT%H:%M:%SZ') [skip ci]" # Push temporary branch git push origin "$TEMP_BRANCH" @@ -156,6 +152,7 @@ jobs: # Merge temp branch into main safely git checkout main git fetch origin main + git rebase origin/main git merge --no-ff --no-edit "$TEMP_BRANCH" # Push main @@ -163,7 +160,6 @@ jobs: # Delete temporary branch on remote git push origin --delete "$TEMP_BRANCH" || true - echo "archives_changed=true" >> $GITEA_OUTPUT # build-and-push-docker-images: