From f49d0adf7cc04d284978be670bbac4a84d808ca7 Mon Sep 17 00:00:00 2001 From: Byungjin Park Date: Sat, 5 Feb 2022 01:07:00 +0900 Subject: [PATCH] Add labeler action --- .github/labeler.yaml | 0 .github/workflows/pull-request-labeler.yaml | 34 +++++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 .github/labeler.yaml create mode 100644 .github/workflows/pull-request-labeler.yaml diff --git a/.github/labeler.yaml b/.github/labeler.yaml new file mode 100644 index 0000000..e69de29 diff --git a/.github/workflows/pull-request-labeler.yaml b/.github/workflows/pull-request-labeler.yaml new file mode 100644 index 0000000..5444153 --- /dev/null +++ b/.github/workflows/pull-request-labeler.yaml @@ -0,0 +1,34 @@ +name: Label Pull Requests + +on: +- pull_request + +jobs: + label-pr: + runs-on: ubuntu-latest + + steps: + - name: Add Labels for PR + uses: actions/labeler@v3 + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}" + configuration-path: .github/labeler.yaml + sync-labels: true + + - name: Add PR Size Labels for PR + uses: codelytv/pr-size-labeler@v1 + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + xs_label: 'size/XS' + xs_max_size: '20' + s_label: 'size/S' + s_max_size: '50' + m_label: 'size/M' + m_max_size: '150' + l_label: 'size/L' + l_max_size: '300' + xl_label: 'size/XL' + fail_if_xl: 'false' + message_if_xl: > + 'This PR has too many changes. + Please make sure you are NOT addressing multiple issues with one PR.'