Skip to content

Commit

Permalink
chore(NA): remove debug step on auto approve backport action (elastic…
Browse files Browse the repository at this point in the history
…#160826)

I believe I found out what was wrong with the previous implementation of
the action.
We were trying to check for the existence of the backport label when the
PR is created which is never there (as it gets added afterwards).

This PR is replacing the checking of the label by the assert that the
branch name on a backport starts with `backport` and the creator of the
PR is kibanamachine.
  • Loading branch information
mistic authored Jun 28, 2023
1 parent 460b311 commit 5ac9390
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/auto-approve-backports.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ jobs:
name: Auto-approve backport
runs-on: ubuntu-latest
if: |
contains(github.event.pull_request_target.labels.*.name, 'backport') &&
github.event.pull_request_target.user.login == 'kibanamachine'
startsWith(github.event.pull_request.head.ref, 'backport') &&
github.event.pull_request.user.login == 'kibanamachine'
permissions:
pull-requests: write
steps:
Expand Down

0 comments on commit 5ac9390

Please sign in to comment.