Skip to content

Commit

Permalink
Enhance PR template + CI workflow for backport labels. (#14779)
Browse files Browse the repository at this point in the history
Signed-off-by: deepthi <[email protected]>
  • Loading branch information
deepthi authored Dec 14, 2023
1 parent 5024180 commit 6b481a7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@

## Checklist

- [ ] "Backport to:" labels have been added if this change should be back-ported
- [ ] "Backport to:" labels have been added if this change should be back-ported to release branches
- [ ] If this change is to be back-ported to previous releases, a justification is included in the PR description
- [ ] Tests were added or are not required
- [ ] Did the new or modified tests pass consistently locally and on the CI
- [ ] Did the new or modified tests pass consistently locally and on CI?
- [ ] Documentation was added or is not required

## Deployment Notes
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/check_label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ jobs:
echo "Expecting PR to not have the NeedsIssue label; please create a linked issue and remove the label."
exit 1
fi
if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'NeedsBackportReason' ; then
if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Backport to:'; then
echo "Expecting PR to not have the NeedsBackportReason label; please add your justification to the PR description and remove the label."
exit 1
fi
fi
- name: Do Not Merge label
Expand Down

0 comments on commit 6b481a7

Please sign in to comment.