From 11818a543cbfcc36c4411509039afb16ef673780 Mon Sep 17 00:00:00 2001 From: Yvo Brevoort Date: Fri, 26 Aug 2022 14:41:03 +0200 Subject: [PATCH] Add php version sniff --- .github/workflows/php-version-sniff.yml | 31 +++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/php-version-sniff.yml diff --git a/.github/workflows/php-version-sniff.yml b/.github/workflows/php-version-sniff.yml new file mode 100644 index 0000000..016293c --- /dev/null +++ b/.github/workflows/php-version-sniff.yml @@ -0,0 +1,31 @@ +--- +name: PHP Version Compatibility + +on: + - push + - pull_request + # Allow manually triggering the workflow. + - workflow_dispatch + +# Cancels all previous workflow runs for the same branch that have not yet completed. +concurrency: + # The concurrency group contains the workflow name and the branch name. + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + php-codesniffer: + strategy: + matrix: + php: [ '8.0', '8.1' ] + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v3 + - uses: pipeline-components/php-codesniffer@master + with: + options: >- + -s + --ignore='*vendor/*' + --standard=PHPCompatibility + --extensions=php + --runtime-set testVersion ${{ matrix.php }}