diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index fb01c9f39..89330aba3 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -33,12 +33,12 @@ jobs: - name: Setup dependencies run: | - composer require -n --no-progress overtrue/phplint - git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-library.git vendor/icinga-php-library - git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-thirdparty.git vendor/icinga-php-thirdparty - git clone --depth 1 https://github.com/Icinga/icingaweb2-module-x509.git vendor/modules/x509-web - git clone --depth 1 https://github.com/Icinga/icingadb-web.git vendor/modules/icingadb-web - git clone --depth 1 https://github.com/Icinga/icingaweb2-module-pdfexport.git vendor/modules/pdfexport-web + composer require -n --no-progress overtrue/phplint phpstan/phpstan + sudo git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-library.git /usr/share/icinga-php/ipl + sudo git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-thirdparty.git /usr/share/icinga-php/vendor + sudo git clone --depth 1 https://github.com/Icinga/icingaweb2-module-x509.git /usr/share/icingaweb2-modules/x509 + sudo git clone --depth 1 https://github.com/Icinga/icingadb-web.git /usr/share/icingaweb2-modules/icingadb + sudo git clone --depth 1 https://github.com/Icinga/icingaweb2-module-pdfexport.git /usr/share/icingaweb2-modules/pdfexport - name: PHP Lint if: ${{ ! cancelled() }} @@ -50,7 +50,7 @@ jobs: - name: PHPStan if: ${{ ! cancelled() }} - uses: php-actions/phpstan@v3 + run: ./vendor/bin/phpstan analyse test: name: Unit tests with php ${{ matrix.php }} on ${{ matrix.os }} diff --git a/phpstan.neon b/phpstan.neon index 9da27bcff..8126806a8 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -52,7 +52,8 @@ parameters: - '#Call to an undefined method ipl\\Sql\\Connection::exec\(\)#' scanDirectories: - - vendor + - /usr/share/icinga-php + - /usr/share/icingaweb2-modules excludePaths: - library/Icinga/Test