From 5dc060c655c5715bab4b9836d90385a3018a2bb7 Mon Sep 17 00:00:00 2001 From: gabemeola <14303404+gabemeola@users.noreply.github.com> Date: Wed, 1 Jul 2026 16:00:05 +0000 Subject: [PATCH] fix: reset PR branch from origin/main instead of rebasing stale branch --- .github/workflows/release-checker.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release-checker.yml b/.github/workflows/release-checker.yml index ea5fd8b..5fd51a2 100644 --- a/.github/workflows/release-checker.yml +++ b/.github/workflows/release-checker.yml @@ -47,16 +47,16 @@ jobs: echo "::notice::Version is up to date ($(cat version.txt | tr -d '[:space:]'))" exit 0 - - name: Rebase PR branch on latest main + - name: Reset PR branch to latest main if: steps.latest.outputs.version != steps.current.outputs.version env: PR_VERSION: ${{ steps.latest.outputs.version }} run: | PR_BRANCH="pr/opencode-release/v${PR_VERSION}" git fetch origin "${{ env.TARGET_BRANCH }}" - git checkout "$PR_BRANCH" 2>/dev/null || git checkout -b "$PR_BRANCH" - git rebase "origin/${{ env.TARGET_BRANCH }}" - git push origin "$PR_BRANCH" --force-with-lease + git branch -D "$PR_BRANCH" 2>/dev/null || true + git checkout -b "$PR_BRANCH" "origin/${{ env.TARGET_BRANCH }}" + git push origin "$PR_BRANCH" --force - name: Bump and create PR if: steps.latest.outputs.version != steps.current.outputs.version