Add 'cleanup' to required PR labels (#8835)
This commit is contained in:
co-authored by
GitHub
parent
a3d3e1c912
commit
8a43741589
@@ -17,7 +17,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
script: |
|
script: |
|
||||||
const labels = context.payload.pull_request.labels.map(label => label.name);
|
const labels = context.payload.pull_request.labels.map(label => label.name);
|
||||||
const requiredLabels = ['bugfix', 'enhancement', 'hardware-support', 'dependencies', 'submodules', 'github_actions', 'trunk'];
|
const requiredLabels = ['bugfix', 'enhancement', 'hardware-support', 'dependencies', 'submodules', 'github_actions', 'trunk', 'cleanup'];
|
||||||
const hasRequiredLabel = labels.some(label => requiredLabels.includes(label));
|
const hasRequiredLabel = labels.some(label => requiredLabels.includes(label));
|
||||||
if (!hasRequiredLabel) {
|
if (!hasRequiredLabel) {
|
||||||
core.setFailed(`PR must have at least one of the following labels before it can be merged: ${requiredLabels.join(', ')}.`);
|
core.setFailed(`PR must have at least one of the following labels before it can be merged: ${requiredLabels.join(', ')}.`);
|
||||||
|
|||||||
Reference in New Issue
Block a user