nucleos / auto-merge-action

🤖 Automerge labeled GitHub Pull Requests.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GitHub AutoMerge Action

Continuous Integration Code Coverage Type Coverage

This GitHub action will scan all open pull requests in the current project and merge them.

The pull request needs to be mergeable (no conflicts), got a green build and contains a label (default: automerge). If the pull request contains an ignore label (default: wip), the pull request will be skipped.

After a succesul merge, the label is removed.

The action is designed to run asynchronously (e.g. every hour, once a day), so it can take a few minutes after the pull request got merged.

Usage

You can create a new workflow that runs every day at 10 AM.

You should not use a very short interval otherwise you will reach the GitHub API limit.

# .github/workflows/automatic-merge.yml
name: "Automatic Merge"

on:
  schedule:
    - cron:  '0 * * * *'

jobs:
  merge:
    name: "Merge Pull Requests"
    runs-on: ubuntu-latest

    steps:
    - name: "Merge"
      uses: "nucleos/auto-merge-action@1.0.0"
      env:
        "GITHUB_TOKEN": ${{ secrets.GITHUB_TOKEN }}

About

🤖 Automerge labeled GitHub Pull Requests.

License:MIT License


Languages

Language:PHP 95.2%Language:Makefile 3.2%Language:Dockerfile 1.2%Language:Shell 0.3%