chore(deps-dev): Bump the dev-minor-patch group with 2 updates #6
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Approve Dependabot pull requests and enable auto-merge so GitHub merges them once | |
| # required status checks pass. Requires: | |
| # - Settings → General → Pull Requests → Allow auto-merge | |
| # - Settings → Actions → General → Allow GitHub Actions to create and approve pull requests | |
| # - Branch protection required status checks (reviews are satisfied by this workflow) | |
| # See: https://docs.github.com/en/code-security/dependabot/working-with-dependabot/automating-dependabot-with-github-actions | |
| # | |
| # All Dependabot version updates (including majors) are auto-approved and auto-merged. | |
| name: dependabot-auto-merge | |
| on: | |
| pull_request_target: | |
| types: [opened, reopened, synchronize] | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| automerge: | |
| # Same-repo Dependabot PRs only. Key off the PR author so synchronize events from | |
| # branch updates (non-Dependabot merge commits) still run. Never check out PR code. | |
| if: > | |
| github.event.pull_request.user.login == 'dependabot[bot]' && | |
| github.event.pull_request.head.repo.full_name == github.repository | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Approve pull request | |
| run: | | |
| set -euo pipefail | |
| if [ "$(gh pr view "$PR" --json reviewDecision -q .reviewDecision)" != "APPROVED" ]; then | |
| gh pr review --approve "$PR" | |
| fi | |
| env: | |
| PR: ${{ github.event.pull_request.html_url }} | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Enable auto-merge | |
| run: | | |
| set -euo pipefail | |
| if [ "$(gh pr view "$PR" --json autoMergeRequest -q '.autoMergeRequest != null')" != "true" ]; then | |
| gh pr merge --auto --squash "$PR" | |
| fi | |
| env: | |
| PR: ${{ github.event.pull_request.html_url }} | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |