diff --git a/.github/labeler.yaml b/.github/labeler.yaml new file mode 100644 index 0000000000..f62f47a815 --- /dev/null +++ b/.github/labeler.yaml @@ -0,0 +1,15 @@ +ci: + - changed-files: + - any-glob-to-any-file: .github/** + +docker: + - changed-files: + - any-glob-to-any-file: docker/** + +documentation: + - changed-files: + - any-glob-to-any-file: docs/** + +dashboard: + - changed-files: + - any-glob-to-any-file: grafana/** diff --git a/.github/workflows/pr-labeling.yaml b/.github/workflows/pr-labeling.yaml new file mode 100644 index 0000000000..3c9a1458e4 --- /dev/null +++ b/.github/workflows/pr-labeling.yaml @@ -0,0 +1,42 @@ +name: 'PR Labeling' + +on: + pull_request_target: + types: + - opened + - synchronize + - reopened + +permissions: + contents: read + pull-requests: write + issues: write + +jobs: + labeler: + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v4 + + - uses: actions/labeler@v5 + with: + configuration-path: ".github/labeler.yaml" + repo-token: "${{ secrets.GITHUB_TOKEN }}" + + size-label: + runs-on: ubuntu-latest + steps: + - uses: pascalgn/size-label-action@v0.5.5 + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" + with: + sizes: > + { + "0": "XS", + "100": "S", + "300": "M", + "1000": "L", + "1500": "XL", + "2000": "XXL" + }