forked from tibdex/backport
-
Notifications
You must be signed in to change notification settings - Fork 3
/
action.yml
63 lines (59 loc) · 2.22 KB
/
action.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Backporting
author: Thibault Derousseaux <[email protected]>
description: >
Automatically backport PRs to other branches by simply labeling them.
inputs:
body_template:
description: >
Lodash template for the backport PR's body.
The data properties are:
- base: backport PR's base branch
- body: original PR's body
- mergeCommitSha: SHA of the original PR's merge commit
- number: original PR's number
default: "Backport <%= mergeCommitSha %> from #<%= number %>."
files_to_skip:
description: Comma seperated list of files to be skipped from the backport
required: false
github_token:
description: Token for the GitHub API.
required: true
head_template:
description: >
Lodash template for the backport PR's head branch.
The data properties are:
- base: backport PR's base branch
- number: original PR's number
default: "backport-<%= number %>-to-<%= base %>"
label_pattern:
description: >
The regular expression pattern that PR labels will be tested on to decide whether the PR should be backported and where.
The backport PR's base branch will be extracted from the pattern's required `base` named capturing group.
default: "^backport (?<base>([^ ]+))$"
labels_template:
description: >
Lodash template compiling to a JSON array of labels to add to the backport PR.
The data properties are:
- base: backport PR's base branch
- labels: array containing the original PR's labels, excluding those matching `label_pattern`.
default: "[]"
title_template:
description: >
Lodash template for the backport PR's title.
The data properties are:
- base: backport PR's base branch
- number: original PR's number
- title: original PR's title
default: "[Backport <%= base %>] <%= title %>"
failure_labels:
description: Comma seperated list of labels to add to the PR with failing backports
required: false
outputs:
created_pull_requests:
description: A JSON stringified object mapping the base branch of the created pull requests to their number.
runs:
using: node16
main: dist/index.js
branding:
icon: arrow-left-circle
color: purple