Add action auto-format for markdown files #61
Workflow file for this run
This file contains 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
name: Auto approve and merge PRs by dependabot | |
on: pull_request_target | |
jobs: | |
autoapprove: | |
name: Auto Approve a PR by dependabot | |
if: github.actor == 'dependabot[bot]' | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Auto approve | |
uses: actions/github-script@v7 | |
with: | |
script: | | |
const result = await github.pulls.createReview({ | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
pull_number: context.issue.number, | |
event: "APPROVE" | |
}) | |
console.log(result.status) | |
automerge: | |
name: Auto merge after successful checks | |
needs: autoapprove | |
if: github.actor == 'dependabot[bot]' | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Auto merge | |
uses: pascalgn/automerge-action@v0.16.2 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
MERGE_LABELS: dependencies | |
MERGE_METHOD: rebase |