name: "Semantic PR Title"

on:
  pull_request_target:
    types:
      - opened
      - edited
      - synchronize

# It's important that we limit the permissions for pull_request_target workflows
# See the waning here: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request_target
permissions:
  pull-requests: read

jobs:
  main:
    name: Validate PR title
    runs-on: ubuntu-latest
    steps:
      - uses: amannn/action-semantic-pull-request@v4
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
