Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 12 additions & 11 deletions .github/workflows/auto-merge.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
name: auto-merge
name: Dependabot auto-merge
on: pull_request

on:
pull_request_target:
permissions:
contents: write
pull-requests: write

jobs:
auto-merge:
dependabot:
runs-on: ubuntu-latest
if: github.actor == 'dependabot[bot]'
if: github.event.pull_request.user.login == 'dependabot[bot]'
steps:
- uses: ahmadnassri/[email protected]
with:
github-token: '${{ secrets.RHACS_BOT_GITHUB_TOKEN }}'
command: "squash and merge"
approve: true
target: minor
- name: Enable auto-merge for Dependabot PRs
run: gh pr merge --auto --squash "$PR_URL" && gh pr review --approve "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
Comment on lines +13 to +17
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hope this would still respect the github checks (even if they are not required). Wouldn't it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vikin91 Nope, checks must be required

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vikin91 Here we have 1 required check so I think it's fine

Loading