Fix phpstan

This commit is contained in:
Laurent Destailleur 2023-08-04 03:42:46 +02:00
parent 2777857f5b
commit 00731380bc
2 changed files with 15 additions and 10 deletions

View File

@ -14,4 +14,6 @@ composer require --dev phpstan/phpstan
Execute:
cd git/dolibarr
mv htdocs/custom /tmp/
php8.2 ../phpstan/htdocs/includes/bin/phpstan -v analyze -a build/phpstan/bootstrap.php htdocs/commande/class -l0 --memory-limit 12G
mv /tmp/custom htdocs

View File

@ -2,17 +2,20 @@ parameters:
customRulesetUsed: true
fileExtensions:
- php
paths:
- htdocs
excludePaths:
- 'htdocs/build/*'
- 'htdocs/custom/*'
- 'htdocs/dev/*'
- 'htdocs/doc/*'
- 'htdocs/documents/*'
- 'htdocs/includes/*'
- 'htdocs/install/doctemplates/*'
- 'htdocs/langs/*'
- 'htdocs/support/*'
- 'htdocs/test/*'
analyseAndScan:
- htdocs/custom
- htdocs/dev/*
- htdocs/doc/*
- htdocs/documents/*
- htdocs/install/doctemplates/*
- htdocs/langs/*
- htdocs/support/*
- htdocs/test/*
analyse:
- htdocs/includes/*
checkAlwaysTrueCheckTypeFunctionCall: false
checkAlwaysTrueInstanceof: false
checkAlwaysTrueStrictComparison: false