Skip to content

Commit

Permalink
🤖 Auto approve cnspec bump PRs (#341)
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Zunker <[email protected]>
  • Loading branch information
czunker authored Dec 5, 2024
1 parent bcf65b1 commit 99b3c69
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions .github/workflows/pr-test-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,17 @@ jobs:
github-token: "${{ secrets.GITHUB_TOKEN }}"
filterOutClosed: true
filterOutDraft: true
- name: Approve a PR
uses: fastify/github-action-merge-dependabot@v3
# fetch a token for the mondoo-mergebot app
- name: Generate token
id: generate-token
uses: actions/create-github-app-token@v1
with:
pr-number: ${{ steps.pr.outputs.number }}
app-id: ${{ secrets.MONDOO_MERGEBOT_APP_ID }}
private-key: ${{ secrets.MONDOO_MERGEBOT_APP_PRIVATE_KEY }}
# automerge using bot token
- name: Approve and merge a PR
run: |
gh pr review ${{ steps.pr.outputs.number }} --approve
gh pr merge ${{ steps.pr.outputs.number }} --squash
env:
GH_TOKEN: ${{ steps.generate-token.outputs.token }}

0 comments on commit 99b3c69

Please sign in to comment.