2022-03-29 22:56:24 +00:00
|
|
|
|
# Reference: https://github.com/CodelyTV/pr-size-labeler
|
|
|
|
|
|
|
|
|
|
name: size-labeler
|
|
|
|
|
|
|
|
|
|
on: [pull_request_target]
|
|
|
|
|
|
2022-10-03 14:53:12 +00:00
|
|
|
|
permissions:
|
|
|
|
|
contents: read
|
|
|
|
|
|
2022-03-29 22:56:24 +00:00
|
|
|
|
jobs:
|
|
|
|
|
size-labeler:
|
2022-10-03 14:53:12 +00:00
|
|
|
|
permissions:
|
|
|
|
|
pull-requests: write # for codelytv/pr-size-labeler to add labels & comment on PRs
|
2022-03-29 22:56:24 +00:00
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
name: Label the PR size
|
|
|
|
|
steps:
|
2022-04-21 12:20:16 +00:00
|
|
|
|
- uses: codelytv/pr-size-labeler@v1.8.1
|
2022-03-29 22:56:24 +00:00
|
|
|
|
with:
|
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
xs_label: 'size/XS'
|
|
|
|
|
xs_max_size: '10'
|
|
|
|
|
s_label: 'size/S'
|
|
|
|
|
s_max_size: '24'
|
|
|
|
|
m_label: 'size/M'
|
|
|
|
|
m_max_size: '99'
|
|
|
|
|
l_label: 'size/L'
|
|
|
|
|
l_max_size: '200'
|
|
|
|
|
xl_label: 'size/XL'
|
|
|
|
|
fail_if_xl: 'false'
|
|
|
|
|
message_if_xl: >
|
|
|
|
|
'This PR exceeds the recommended size of 200 lines.
|
|
|
|
|
Please make sure you are NOT addressing multiple issues with one PR.
|
|
|
|
|
Note this PR might be rejected due to its size.’
|