From 75ec5465509edcb1f4b3b9c43f44e0f123a6f5c1 Mon Sep 17 00:00:00 2001 From: SlamBamActionman <83650252+SlamBamActionman@users.noreply.github.com> Date: Thu, 14 Nov 2024 14:57:05 +0100 Subject: [PATCH] Update Label workflows to use new labels (#33310) * Update labeler.yml * Update labeler-needsreview.yml * Update labeler-staging.yml * Update labeler-stable.yml * Update labeler-untriaged.yml * Create labeler-size.yml * Update labeler-size.yml * Update labeler-size.yml * Update conflict-labeler.yml * Rename conflict-labeler.yml to labeler-conflict.yml --- .github/labeler.yml | 2 +- ...flict-labeler.yml => labeler-conflict.yml} | 2 +- .github/workflows/labeler-needsreview.yml | 4 ++-- .github/workflows/labeler-size.yml | 20 +++++++++++++++++++ .github/workflows/labeler-stable.yml | 2 +- .github/workflows/labeler-staging.yml | 2 +- .github/workflows/labeler-untriaged.yml | 4 +++- 7 files changed, 29 insertions(+), 7 deletions(-) rename .github/workflows/{conflict-labeler.yml => labeler-conflict.yml} (93%) create mode 100644 .github/workflows/labeler-size.yml diff --git a/.github/labeler.yml b/.github/labeler.yml index 97b402eda9ff1c..69b2ca87749c6e 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -16,7 +16,7 @@ - changed-files: - any-glob-to-any-file: '**/*.swsl' -"No C#": +"Changes: No C#": - changed-files: # Equiv to any-glob-to-all as long as this has one matcher. If ALL changed files are not C# files, then apply label. - all-globs-to-all-files: "!**/*.cs" diff --git a/.github/workflows/conflict-labeler.yml b/.github/workflows/labeler-conflict.yml similarity index 93% rename from .github/workflows/conflict-labeler.yml rename to .github/workflows/labeler-conflict.yml index 1e2125c30a23b9..ebcc54d4604daf 100644 --- a/.github/workflows/conflict-labeler.yml +++ b/.github/workflows/labeler-conflict.yml @@ -16,6 +16,6 @@ jobs: - name: Check for Merge Conflicts uses: eps1lon/actions-label-merge-conflict@v3.0.0 with: - dirtyLabel: "Merge Conflict" + dirtyLabel: "S: Merge Conflict" repoToken: "${{ secrets.GITHUB_TOKEN }}" commentOnDirty: "This pull request has conflicts, please resolve those before we can evaluate the pull request." diff --git a/.github/workflows/labeler-needsreview.yml b/.github/workflows/labeler-needsreview.yml index 311048acb0f3e6..819b34b7bbd381 100644 --- a/.github/workflows/labeler-needsreview.yml +++ b/.github/workflows/labeler-needsreview.yml @@ -10,7 +10,7 @@ jobs: steps: - uses: actions-ecosystem/action-add-labels@v1 with: - labels: "Status: Needs Review" + labels: "S: Needs Review" - uses: actions-ecosystem/action-remove-labels@v1 with: - labels: "Status: Awaiting Changes" + labels: "S: Awaiting Changes" diff --git a/.github/workflows/labeler-size.yml b/.github/workflows/labeler-size.yml new file mode 100644 index 00000000000000..ad6e35c829291a --- /dev/null +++ b/.github/workflows/labeler-size.yml @@ -0,0 +1,20 @@ +name: "Labels: Size" +on: pull_request_target +jobs: + size-label: + runs-on: ubuntu-latest + steps: + - name: size-label + uses: "pascalgn/size-label-action@v0.5.5" + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" + with: + # Custom size configuration + sizes: > + { + "0": "XS", + "10": "S", + "30": "M", + "100": "L", + "1000": "XL" + } diff --git a/.github/workflows/labeler-stable.yml b/.github/workflows/labeler-stable.yml index 491d6a76fad509..f6fd2033a11b6f 100644 --- a/.github/workflows/labeler-stable.yml +++ b/.github/workflows/labeler-stable.yml @@ -13,4 +13,4 @@ jobs: steps: - uses: actions-ecosystem/action-add-labels@v1 with: - labels: "Branch: stable" + labels: "Branch: Stable" diff --git a/.github/workflows/labeler-staging.yml b/.github/workflows/labeler-staging.yml index e31a5a482f2db5..b46a198aefb558 100644 --- a/.github/workflows/labeler-staging.yml +++ b/.github/workflows/labeler-staging.yml @@ -13,4 +13,4 @@ jobs: steps: - uses: actions-ecosystem/action-add-labels@v1 with: - labels: "Branch: staging" + labels: "Branch: Staging" diff --git a/.github/workflows/labeler-untriaged.yml b/.github/workflows/labeler-untriaged.yml index 775aab265468af..ec1d194851c5c7 100644 --- a/.github/workflows/labeler-untriaged.yml +++ b/.github/workflows/labeler-untriaged.yml @@ -3,6 +3,8 @@ on: issues: types: [opened] + pull_request_target: + types: [opened] jobs: add_label: @@ -11,4 +13,4 @@ jobs: - uses: actions-ecosystem/action-add-labels@v1 if: join(github.event.issue.labels) == '' with: - labels: "Status: Untriaged" + labels: "S: Untriaged"