From 9cfc9bb8a87ff3c125bb614ead803db40ea5a244 Mon Sep 17 00:00:00 2001 From: Marcus Hert Da Coregio Date: Wed, 10 Jul 2024 12:47:05 -0300 Subject: [PATCH] Use in:title Issue gh-14484 --- .github/workflows/mark-duplicate-dependabot-prs.yml | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/.github/workflows/mark-duplicate-dependabot-prs.yml b/.github/workflows/mark-duplicate-dependabot-prs.yml index ff4217a8ab..7d1574309d 100644 --- a/.github/workflows/mark-duplicate-dependabot-prs.yml +++ b/.github/workflows/mark-duplicate-dependabot-prs.yml @@ -1,18 +1,10 @@ -name: Mark Duplicate PRs +name: Mark Duplicate Dependabot PRs on: pull_request: types: [closed] jobs: - debug: - runs-on: ubuntu-latest - steps: - - name: Debug Event Payload - run: | - echo "Merged: ${{ github.event.pull_request.merged }}" - echo "User Login: ${{ github.event.pull_request.user.login }}" - check_duplicate_prs: runs-on: ubuntu-latest if: github.event.pull_request.merged == true && github.event.pull_request.user.login == 'dependabot[bot]' @@ -33,7 +25,7 @@ jobs: DEPENDENCY_NAME: ${{ steps.extract.outputs.dependency_name }} GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - PRS=$(gh pr list --search "milestone:${{ github.event.pull_request.milestone.title }} is:merged $DEPENDENCY_NAME" --json number --jq 'map(.number) | join(",")') + PRS=$(gh pr list --search 'milestone:${{ github.event.pull_request.milestone.title }} is:merged in:title "$DEPENDENCY_NAME"' --json number --jq 'map(.number) | join(",")') echo "prs=$PRS" >> $GITHUB_OUTPUT - name: Label Duplicate PRs