name: Code Style

on:
  pull_request:
  push:
    branches:
      - "0.x"

jobs:
  check-code-style:
    runs-on: ubuntu-20.04

    steps:
      - uses: actions/checkout@v3
        with:
          ref: ${{ github.event.pull_request.head.sha }}
          token: ${{ secrets.PAT }}

      - name: Run php-cs-fixer
        uses: docker://oskarstark/php-cs-fixer-ga:2.19.0
