Skip to content

Instantly share code, notes, and snippets.

@PurpleBooth
Created September 16, 2022 05:37
Show Gist options
  • Save PurpleBooth/2d3892e582ee1c80e96508b8f356c8e9 to your computer and use it in GitHub Desktop.
Save PurpleBooth/2d3892e582ee1c80e96508b8f356c8e9 to your computer and use it in GitHub Desktop.
dependabot:
needs: [ validate ]
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' && ( github.head_ref || github.ref_name ) != 'main' }}
steps:
- name: Enable auto-merge for Dependabot PRs
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment