name: Apply clang-format to PR

on:
  pull_request:
    types: [labeled]

jobs:
  clang-format:
    runs-on: ubuntu-latest
    permissions:
      pull-requests: write

    steps:
    - uses: actions/checkout@v4
      with:
         fetch-depth: 0
    - uses: InsightSoftwareConsortium/ITKApplyClangFormatAction@master
      with:
        github-token: ${{ secrets.GITHUB_TOKEN }}
