name: Clang-Format

on:
  push:
  pull_request:
  merge_group:
   
jobs:
  build:
    name: Format
    runs-on: ubuntu-20.04
    
    steps:
    - uses: actions/checkout@v4
    - uses: DoozyX/clang-format-lint-action@v0.18.2
      with:
        source: 'enzyme/Enzyme enzyme/tools/enzyme-tblgen'
        exclude: './CMakeLists.txt enzyme/Enzyme/SCEV'
        style: 'llvm'
        clangFormatVersion: 16
