Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions .github/workflows/conventional-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,22 @@ on: # yamllint disable-line rule:truthy
pull_request:
types: [opened, synchronize, reopened, edited]

permissions:
contents: read

jobs:
validate-pr-title:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: PR Conventional Commit Validation
uses: ytanikin/pr-conventional-commits@1.5.2
uses: ytanikin/pr-conventional-commits@639145d78959c53c43112365837e3abd21ed67c1 # 1.5.2
with:
task_types: '["feat","fix","docs","test","ci","refactor","perf","chore","revert"]'
add_label: true
add_scope_label: true
# A pull request from a fork gets a read-only token: labelling it
# fails the job even when the title is valid. Only label pull
# requests opened from a branch of this repository.
add_label: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
add_scope_label: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
Loading