Skip to content

fix: test PR

fix: test PR #6

Workflow file for this run

name: Label PR
on:
pull_request:
types:
- opened
- edited
branches:
- master
- feature/v3 #TODO: remove
concurrency:
group: label-pr-${{ github.event.pull_request.number }}
cancel-in-progress: true
jobs:
label-pr:
if: github.event.action == 'opened' || github.event.changes.title
runs-on: ubuntu-latest
steps:
- name: Update PR labels
id: update-pr-labels
uses: ytanikin/pr-conventional-commits@1.5.2
with:
task_types: '["feat","fix","docs","ci"]'
continue-on-error: true
- name: Warn about invalid PR title
if: steps.update-pr-labels.outcome == 'failure'
run: gh pr comment "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --body "$BODY"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_NUMBER: ${{ github.event.pull_request.number }}
BODY: |
👋 Hey @${{ github.event.pull_request.user.login }}, it looks like the PR title doesn't follow the [Conventional Commits](https://www.conventionalcommits.org) format.
While it's not a blocker for this PR, following the conventional commits format helps us to automatically calculate next release version, categorize changes and generate changelog.
Good candidates might be `feat: ${{ github.event.pull_request.title }}` or `fix: ${{ github.event.pull_request.title }}`. You can also add `!` to indicate a breaking change, e.g. `feat!: ${{ github.event.pull_request.title }}`.
Please follow the [Conventional Commits](https://www.conventionalcommits.org) for more details and examples. 🙌