Commit aec04ab558 for woocommerce

commit aec04ab558e6ff09c24cde49ca5e9a067843527f
Author: Alba Rincón <albarin@users.noreply.github.com>
Date:   Mon Dec 1 11:05:34 2025 +0100

    Apply `Release` label and PR reviewer for release related PRs (#62139)

    * Skip the automatic PR reviewer for release related PRs

    * Asign `Release` label to all release related PRs

    * Add the gh actor to changelog PRs

    * Pass the ga param to the changelog command

    * Fix command error

    * Use woocommerce bot since it has permissions to add labels

    * Remove changes for changelog

    * Remove unnecessary reviewer

    * Add the pr author as reviewer

diff --git a/.github/workflows/automate-team-review-assignment.yml b/.github/workflows/automate-team-review-assignment.yml
index 2287c6b0b1..594462a920 100644
--- a/.github/workflows/automate-team-review-assignment.yml
+++ b/.github/workflows/automate-team-review-assignment.yml
@@ -73,7 +73,7 @@ jobs:
               token: ${{ secrets.PR_ASSIGN_TOKEN }}

         - name: Assign reviewers for a teams PR
-          if: ${{ steps.check.outputs.contributor == 'no' && github.event.pull_request.draft == false }}
+          if: ${{ steps.check.outputs.contributor == 'no' && github.event.pull_request.draft == false && ! contains( github.event.pull_request.labels.*.name, 'Release' ) }}
           continue-on-error: ${{ ( github.event.pull_request.head.repo.fork && 'true' ) || 'false' }}
           uses: acq688/Request-Reviewer-For-Team-Action@fca1c60fd0504aef59bdc925f3902c8a2d8bce62 # v1.1
           with:
diff --git a/.github/workflows/release-bump-version.yml b/.github/workflows/release-bump-version.yml
index 2ace76d284..e067d5c377 100644
--- a/.github/workflows/release-bump-version.yml
+++ b/.github/workflows/release-bump-version.yml
@@ -171,5 +171,6 @@ jobs:
             --body 'This PR updates the versions in ${{ inputs.branch }} to ${{ steps.compute-new-version.outputs.nextVersion }}.' \
             --base ${{ inputs.branch }} \
             --head ${branch_name} \
-            --label Release
+            --label Release \
+            --reviewer "${{ github.actor }}"

diff --git a/.github/workflows/release-update-stable-tag.yml b/.github/workflows/release-update-stable-tag.yml
index e4ad4bf5a8..715f622d21 100644
--- a/.github/workflows/release-update-stable-tag.yml
+++ b/.github/workflows/release-update-stable-tag.yml
@@ -238,14 +238,14 @@ jobs:

       - name: Configure Git
         run: |
-          git config user.name github-actions
-          git config user.email github-actions@github.com
+          git config --global user.name "woocommercebot"
+          git config --global user.email "woocommercebot@users.noreply.github.com"

       - name: Update stable tag on ${{ matrix.branch }}
         env:
           TARGET_VERSION: ${{ needs.validate-release.outputs.version }}
           BRANCH_NAME: ${{ matrix.branch }}
-          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          GH_TOKEN: ${{ secrets.WC_BOT_PR_CREATE_TOKEN || secrets.GITHUB_TOKEN }}
         run: |
           echo "🔄 Processing branch: $BRANCH_NAME..."

@@ -280,7 +280,8 @@ jobs:
               --body "This PR updates the stable tag to $TARGET_VERSION." \
               --base "$BRANCH_NAME" \
               --head "$UPDATE_BRANCH" \
-              --reviewer ${{ github.actor }}
+              --reviewer ${{ github.actor }} \
+              --label Release

             echo "✅ Successfully created PR to update stable tag to $TARGET_VERSION on $BRANCH_NAME"
           fi
diff --git a/.github/workflows/shared-cherry-pick.yml b/.github/workflows/shared-cherry-pick.yml
index 07bc5b20af..73d93c058f 100644
--- a/.github/workflows/shared-cherry-pick.yml
+++ b/.github/workflows/shared-cherry-pick.yml
@@ -279,11 +279,26 @@ jobs:
                 title: `[Backport to ${targetBranch}] ${originalPr.title}`,
                 body: prBody
               });
-
+
+              // Add "Release" label to the PR
+              await github.rest.issues.addLabels({
+                owner: context.repo.owner,
+                repo: context.repo.repo,
+                issue_number: newPr.number,
+                labels: ['Release']
+              });
+
+              await github.rest.pulls.requestReviewers({
+                owner: context.repo.owner,
+                repo: context.repo.repo,
+                pull_number: newPr.number,
+                reviewers: [context.actor, originalPr.user.login]
+              });
+
               core.setOutput('pr_number', newPr.number.toString());
               core.setOutput('original_author', originalPr.user?.login || '');
               core.setOutput('original_merger', originalPr.merged_by?.login || '');
-
+
               core.info(`Created PR #${newPr.number}: ${newPr.html_url}`);

             } catch (error) {