diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 0000000000000..47f755f43caaa --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,23 @@ +cli: +- changed-files: + - any-glob-to-any-file: cli/** + +documentation: +- changed-files: + - any-glob-to-any-file: docs/** + +🖥️web: +- changed-files: + - any-glob-to-any-file: web/** + +📱mobile: +- changed-files: + - any-glob-to-any-file: mobile/** + +🗄️server: +- changed-files: + - any-glob-to-any-file: server/** + +🧠machine-learning: +- changed-files: + - any-glob-to-any-file: machine-learning/** diff --git a/.github/workflows/pr-labeler.yml b/.github/workflows/pr-labeler.yml new file mode 100644 index 0000000000000..e57cd86e2b3c7 --- /dev/null +++ b/.github/workflows/pr-labeler.yml @@ -0,0 +1,12 @@ +name: "Pull Request Labeler" +on: +- pull_request_target + +jobs: + labeler: + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@v5 diff --git a/.github/workflows/pr-require-label.yml b/.github/workflows/pr-require-label.yml index 6bf54eacf1e08..ef157103323ee 100644 --- a/.github/workflows/pr-require-label.yml +++ b/.github/workflows/pr-require-label.yml @@ -3,6 +3,10 @@ name: Enforce PR labels on: pull_request: types: [labeled, unlabeled, opened, edited, synchronize] + workflow_run: + workflows: ["Pull Request Labeler"] + types: + - completed jobs: enforce-label: name: Enforce label