Skip to content
Snippets Groups Projects
Verified Commit 9b9a4ad2 authored by Bartek Jaskulski's avatar Bartek Jaskulski
Browse files

refactor: remove hardcoded phpstan level, let project control

parent c14dedf8
No related branches found
No related tags found
No related merge requests found
......@@ -9,12 +9,12 @@ phpstan:
script:
- |
if [ -f "vendor/bin/phpstan" ]; then
vendor/bin/phpstan analyse --level 5 --error-format=gitlab --memory-limit=2G > phpstan-codequality.json || true
vendor/bin/phpstan analyse --level 5 --error-format=junit --memory-limit=2G > phpstan-junit.xml
vendor/bin/phpstan analyse --error-format=gitlab --memory-limit=2G > phpstan-codequality.json || true
vendor/bin/phpstan analyse --error-format=junit --memory-limit=2G > phpstan-junit.xml
elif [ -f "vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan" ]; then
# PHPStan installed by director
vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan analyse --level 5 --error-format=gitlab --memory-limit=2G > phpstan-codequality.json || true
vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan analyse --level 5 --error-format=junit --memory-limit=2G > phpstan-junit.xml
vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan analyse --error-format=gitlab --memory-limit=2G > phpstan-codequality.json || true
vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan analyse --error-format=junit --memory-limit=2G > phpstan-junit.xml
else
echo "PHPStan not found! Install it with 'composer require --dev wpdesk/phpstan-rules'."
exit 125
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment