This GitHub Action automatically merges pending pull requests (PRs) generated by Release-Please. It filters PRs by a specified GitHub App author and label, then adds a custom label to the identified PR before merging. The action is configurable with inputs for the repository, GitHub token, labels, and app author.
To use this action in your workflow, you need to specify the repository, GitHub token, labels, and app author. The action will automatically identify and merge the relevant PRs.
name: Auto Merge PRs
on: [push]
jobs:
auto-merge:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Auto Merge PRs
uses: liblaf/actions/auto-merge@main
with:
token: ${{ secrets.GITHUB_TOKEN }}
add-label: automerge
app: github-actions
label: "autorelease: pending"
repo: ${{ github.repository }}
Input Name | Description | Required | Default Value |
---|---|---|---|
token |
GitHub Token. | No | ${{ github.token }} |
add-label |
Add labels by name. | No | automerge |
app |
Filter by GitHub App author. | No | github-actions |
label |
Filter by label. | No | "autorelease: pending" |
repo |
Repository name with owner. | No | ${{ github.repository }} |
This project is licensed under the MIT License. See the LICENSE file for details.