feat(dev-tools): Mise en place phpcs+phpstan #4829
Merged
JamesRezo
merged 1 commits from qa-tools
into master
1 year ago
8 changed files with 191 additions and 17 deletions
@ -0,0 +1,7 @@
|
||||
/vendor/ |
||||
/composer.phar |
||||
/composer.lock |
||||
/phpcs.xml |
||||
/phpstan.neon |
||||
/.php_cs.cache |
||||
/.php_cs.txt |
@ -0,0 +1,7 @@
|
||||
{ |
||||
"require-dev": { |
||||
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.1", |
||||
"spip/coding-standards": "^1.2", |
||||
"phpstan/phpstan": "^0.12.98" |
||||
} |
||||
} |
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0"?> |
||||
<ruleset> |
||||
<file>.</file> |
||||
<exclude-pattern>vendor/*</exclude-pattern> |
||||
<exclude-pattern>lang/*</exclude-pattern> |
||||
<exclude-pattern>lib/*</exclude-pattern> |
||||
|
||||
<rule ref="SPIP41"/> |
||||
|
||||
<config name="ignore_warnings_on_exit" value="1"/> |
||||
<arg name="cache" value=".php_cs.cache"/> |
||||
<arg name="report-full" value=".php_cs.txt"/> |
||||
<arg name="report-summary"/> |
||||
<arg value="s"/> |
||||
</ruleset> |
@ -0,0 +1,132 @@
|
||||
parameters: |
||||
ignoreErrors: |
||||
- |
||||
message: "#^Function _T not found\\.$#" |
||||
count: 11 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function _request not found\\.$#" |
||||
count: 4 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function autoriser not found\\.$#" |
||||
count: 2 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function id_table_objet not found\\.$#" |
||||
count: 1 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function include_spip not found\\.$#" |
||||
count: 3 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function objet_modifier not found\\.$#" |
||||
count: 1 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function objet_type not found\\.$#" |
||||
count: 1 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function sql_allfetsel not found\\.$#" |
||||
count: 2 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function sql_in not found\\.$#" |
||||
count: 2 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function sql_quote not found\\.$#" |
||||
count: 2 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function table_objet_sql not found\\.$#" |
||||
count: 1 |
||||
path: action/deplacer_objets.php |
||||
|
||||
- |
||||
message: "#^Function _request not found\\.$#" |
||||
count: 3 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function autoriser not found\\.$#" |
||||
count: 1 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function include_spip not found\\.$#" |
||||
count: 3 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function recuperer_fond not found\\.$#" |
||||
count: 1 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function table_objet not found\\.$#" |
||||
count: 1 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function trouver_fond not found\\.$#" |
||||
count: 1 |
||||
path: action/plan.php |
||||
|
||||
- |
||||
message: "#^Function charger_fonction not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function include_spip not found\\.$#" |
||||
count: 2 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function lister_tables_objets_sql not found\\.$#" |
||||
count: 2 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function session_get not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function statut_image not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function statut_titre not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function statuts_articles_visibles not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function trouver_fond not found\\.$#" |
||||
count: 1 |
||||
path: plan_fonctions.php |
||||
|
||||
- |
||||
message: "#^Function include_spip not found\\.$#" |
||||
count: 2 |
||||
path: prive/squelettes/inclure/plan-articles_fonctions.php |
||||
|
@ -0,0 +1,12 @@
|
||||
includes: |
||||
- phpstan-baseline.neon |
||||
|
||||
parameters: |
||||
paths: |
||||
- . |
||||
excludePaths: |
||||
analyseAndScan: |
||||
- vendor |
||||
- lang |
||||
- lib |
||||
level: 0 |
Loading…
Reference in new issue