-
Notifications
You must be signed in to change notification settings - Fork 109
37 lines (33 loc) · 1.19 KB
/
merge.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Merge the current PR
on:
repository_dispatch:
types:
- merge-command
jobs:
automerge:
name: Merge
runs-on: ubuntu-latest
steps:
- name: Add the merge-requested label
uses: actions-ecosystem/action-add-labels@v1
with:
github_token: "${{ secrets.CI_TOKEN }}"
number: ${{ github.event.client_payload.github.payload.issue.number }}
labels: merge-requested
- name: Automerge
uses: pascalgn/[email protected]
env:
GITHUB_TOKEN: "${{ secrets.CI_TOKEN }}"
MERGE_LABELS: "merge-requested,!hold"
MERGE_METHOD: "rebase"
MERGE_RETRY_SLEEP: "30000" # 30 seconds
# Use a fake UPDATE_LABEL, to prevent rebase from being triggered
# https://github.com/pascalgn/automerge-action/issues/86
UPDATE_LABELS: "never-perform-rebase,!hold"
UPDATE_METHOD: "rebase"
- name: Remove the merge-requested label
uses: actions-ecosystem/action-remove-labels@v1
with:
github_token: "${{ secrets.CI_TOKEN }}"
number: ${{ github.event.client_payload.github.payload.issue.number }}
labels: merge-requested