Skip to content

Commit

Permalink
Add dependabot auto-merge (#125)
Browse files Browse the repository at this point in the history
adracus authored Apr 11, 2023
1 parent 992081d commit 00862ad
Showing 6 changed files with 68 additions and 1 deletion.
27 changes: 27 additions & 0 deletions .github/workflows/dependabot-auto-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Dependabot auto-merge
on: pull_request

permissions:
contents: write
pull-requests: write

jobs:
dependabot:
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' }}
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v1
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
- name: Approve the PR
run: gh pr review --approve "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Enable auto-merge for Dependabot PRs
run: gh pr merge --auto --squash "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
13 changes: 13 additions & 0 deletions .github/workflows/docs-kustomize-validation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Kustomize Validation

on:
pull_request:
paths:
- 'docs/**'
- '**/*.md'

jobs:
kustomize-validation:
runs-on: ubuntu-latest
steps:
- run: 'echo "No kustomize validation required"'
13 changes: 13 additions & 0 deletions .github/workflows/docs-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Lint Docs

on:
pull_request:
paths:
- 'docs/**'
- '**/*.md'

jobs:
lint:
runs-on: ubuntu-latest
steps:
- run: 'echo "No lint required"'
14 changes: 14 additions & 0 deletions .github/workflows/docs-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Pull Request Docs test

on:
pull_request:
paths:
- 'docs/**'
- '**/*.md'

jobs:
checks:
name: test
runs-on: ubuntu-latest
steps:
- run: 'echo "No test required"'
File renamed without changes.
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -9,7 +9,7 @@ on:

jobs:
checks:
name: run
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

0 comments on commit 00862ad

Please sign in to comment.