Skip to content

Commit

Permalink
Setup Dependabot auto-merge CI workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
viral32111 committed Dec 6, 2023
1 parent b0f8346 commit 232171b
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 3 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/automerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Dependabot Auto-Merge

on:
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
workflow_dispatch:

jobs:
dependabot-auto-merge:
name: Dependabot Auto-Merge
runs-on: ubuntu-latest
if: github.actor == 'dependabot[bot]'
permissions:
contents: write
pull-requests: write
issues: write
steps:
- name: Clone repository
uses: actions/checkout@v3

- name: Fetch Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Enable auto-merge for pull request
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh pr merge --auto --rebase ${{ github.event.pull_request.html_url }}
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
- 'src/**/*'
- '*.gradle.kts'
- 'gradle.properties'
- '.github/workflows/ci.yml'
- '.github/workflows/*.yml'
branches:
- '**'
tags:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ name: CodeQL
on:
push:
paths:
- '**'
- '**'
branches:
- '**'
- '**'
schedule:
- cron: '0 0 * * 0'

Expand Down

0 comments on commit 232171b

Please sign in to comment.