-
-
Notifications
You must be signed in to change notification settings - Fork 347
37 lines (31 loc) · 1.01 KB
/
backport.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: Automatic Backport
on:
pull_request_target:
types: ["labeled", "closed"]
jobs:
backport:
if: startsWith(github.event.pull_request.labels.*.name, 'backport-to-')
name: Backport PR
runs-on: ubuntu-latest
steps:
- name: Write json
id: create-json
uses: jsdaniell/[email protected]
with:
name: ".backportrc.json"
json: |
{
"targetPRLabels": "backport",
"prTitle": "[{{sourceBranch}} to {{targetBranch}}] backport: {{sourcePullRequest.title}} ({{sourcePullRequest.number}})"
}
- name: Backport Action
uses: sorenlouv/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
auto_backport_label_prefix: backport-to-
- name: Info log
if: ${{ success() }}
run: cat ~/.backport/backport.info.log
- name: Debug log
if: ${{ failure() }}
run: cat ~/.backport/backport.debug.log