diff --git a/.github/workflows/labels.yaml b/.github/workflows/labels.yaml new file mode 100644 index 0000000000..4d655fb387 --- /dev/null +++ b/.github/workflows/labels.yaml @@ -0,0 +1,49 @@ +name: Conventional Commit Labels +on: + pull_request_target: + types: [opened, synchronize, reopened] + +jobs: + assign-labels: + runs-on: ubuntu-latest + name: Assign labels in pull request + if: github.event.pull_request.merged == false + steps: + - name: Execute assign labels + id: action-assign-labels + uses: mauroalderete/action-assign-labels@v1 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + conventional-commits: | + conventional-commits: + - type: 'fix' + nouns: ['fix'] + labels: ['fix'] + - type: 'feat' + nouns: ['feat'] + labels: ['feat'] + - type: 'build' + nouns: ['build'] + labels: ['build'] + - type: 'chore' + nouns: ['chore'] + labels: ['chore'] + - type: 'ci' + nouns: ['ci'] + labels: ['ci'] + - type: 'docs' + nouns: ['docs'] + labels: ['docs'] + - type: 'style' + nouns: ['style'] + labels: ['style'] + - type: 'refactor' + nouns: ['refactor'] + labels: ['refactor'] + - type: 'perf' + nouns: ['perf'] + labels: ['perf'] + - type: 'test' + nouns: ['test'] + labels: ['test'] + \ No newline at end of file