From 727562b02fc1197b66f3794fbd2b7c00699da44b Mon Sep 17 00:00:00 2001 From: NicolasMerget Date: Fri, 22 Jul 2022 16:39:23 +0200 Subject: [PATCH 1/2] feat: add labeler.yml --- .github/labeler.yml | 44 +++++++++++++++++++++++++++++++++++ .github/workflows/labeler.yml | 14 +++++++++++ 2 files changed, 58 insertions(+) create mode 100644 .github/labeler.yml create mode 100644 .github/workflows/labeler.yml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 000000000..081086a6a --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,44 @@ +# Add 'repo' label to any root file changes +repo: + - '*' + +# Add 'cicd' label to any file changes inside .github dir +cicd: + - .github/* + - .github/**/* + +# Add 'stencil' label to any file changes for stencil +stencil: + - packages/db-ui-elements-stencil/** + +# Add 'angular' label to any file changes for angular-build-target +angular: + - packages/db-ui-elements-angular/** + +# Add 'react' label to any file changes for angular-build-target +react: + - packages/db-ui-elements-react/** + +# Add 'vue' label to any file changes for angular-build-target +vue: + - packages/db-ui-elements-vue/** + +# Add 'angular-showcase' label to any file changes for angular-showcase +angular-showcase: + - showcase/angular-showcase/** + +# Add 'playground-showcase' label to any file changes for playground-showcase +playground-showcase: + - showcase/playground-showcase/** + +# Add 'react-showcase' label to any file changes for react-showcase +react-showcase: + - showcase/react-showcase/** + +# Add 'reactwind-showcase' label to any file changes for reactwind-showcase +reactwind-showcase: + - showcase/reactwind-showcase/** + +# Add 'vue-showcase' label to any file changes for vue-showcase +vue-showcase: + - showcase/vue-showcase/** diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml new file mode 100644 index 000000000..6627974e2 --- /dev/null +++ b/.github/workflows/labeler.yml @@ -0,0 +1,14 @@ +name: 'Pull Request Labeler' +on: + - pull_request_target + +jobs: + triage: + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@v4 + with: + repo-token: '${{ secrets.GITHUB_TOKEN }}' From 09a26c638ff10ff8b42b910dc678347e013766d6 Mon Sep 17 00:00:00 2001 From: NicolasMerget Date: Fri, 22 Jul 2022 17:05:19 +0200 Subject: [PATCH 2/2] fix: issue with pull_request_target --- .github/workflows/labeler.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index 6627974e2..0406f45dd 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -1,6 +1,5 @@ name: 'Pull Request Labeler' -on: - - pull_request_target +on: [pull_request] jobs: triage: @@ -12,3 +11,4 @@ jobs: - uses: actions/labeler@v4 with: repo-token: '${{ secrets.GITHUB_TOKEN }}' + sync-labels: true