diff --git a/.github/workflows/automerge.yml b/.github/workflows/automerge.yml index 393e12f..2d0e1c7 100644 --- a/.github/workflows/automerge.yml +++ b/.github/workflows/automerge.yml @@ -6,21 +6,15 @@ name: Automerge release bump PR on: pull_request_target: types: - - labeled - - unlabeled - - synchronize - opened - - edited - - ready_for_review - - reopened - - unlocked - pull_request_review: - types: - - submitted + - synchronize jobs: autoapprove: - if: github.event.pull_request.draft == false && (github.actor == 'asyncapi-bot' || github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]') && !contains(github.event.pull_request.labels.*.name, 'released') + if: > + contains(fromJson('["asyncapi-bot", "dependabot[bot]", "dependabot-preview[bot]"]'), github.event.pull_request.user.login) && + contains(fromJson('["asyncapi-bot", "dependabot[bot]", "dependabot-preview[bot]"]'), github.actor) && + !contains(github.event.pull_request.labels.*.name, 'released') runs-on: ubuntu-latest steps: - name: Autoapproving @@ -42,7 +36,6 @@ jobs: automerge: needs: [autoapprove] - if: github.event.pull_request.user.login == 'asyncapi-bot' || github.event.pull_request.user.login == 'dependabot[bot]' || github.event.pull_request.user.login == 'dependabot-preview[bot]' runs-on: ubuntu-latest steps: - name: Automerging