From e6205fc15e40fbd1480e350b361f5a225e294c50 Mon Sep 17 00:00:00 2001 From: Aleksandr Pasevin Date: Tue, 12 Aug 2025 16:58:14 +0300 Subject: [PATCH] fix(ci): checkout proper branch before committing in update-versions workflow --- .github/workflows/update-versions.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/update-versions.yml b/.github/workflows/update-versions.yml index 24e37f238..575293117 100644 --- a/.github/workflows/update-versions.yml +++ b/.github/workflows/update-versions.yml @@ -63,6 +63,9 @@ jobs: run: | git config --local user.email "github-actions[bot]@users.noreply.github.com" git config --local user.name "github-actions[bot]" + # Checkout the proper branch (handle both PR and push events) + BRANCH_NAME="${{ github.head_ref || github.ref_name }}" + git checkout "$BRANCH_NAME" git add packages/builder/src/export/versions.ts git commit -m "chore: update export versions" - git push + git push origin "$BRANCH_NAME"