-
-
Notifications
You must be signed in to change notification settings - Fork 20
/
phpstan.neon.dist
32 lines (31 loc) · 1.21 KB
/
phpstan.neon.dist
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Magic behaviour with __get, __set, __call and __callStatic is not exactly static analyser-friendly :)
# Fortunately, You can ignore it by the following config.
#
# vendor/bin/phpstan analyse app --memory-limit 200M -l 0
#
includes:
# 需要执行 composer require phpstan/phpstan-deprecation-rules --dev
# - vendor/phpstan/phpstan-deprecation-rules/rules.neon
parameters:
level: 0
paths:
- app
- config
reportUnmatchedIgnoredErrors: false
parallel:
jobSize: 20
maximumNumberOfProcesses: 32
minimumNumberOfJobsPerProcess: 2
ignoreErrors:
- '#Static call to instance method Hyperf\\HttpServer\\Router\\Router::[a-zA-Z0-9\\_]+\(\)#'
- '#Static call to instance method Hyperf\\DbConnection\\Db::[a-zA-Z0-9\\_]+\(\)#'
services:
# When using `match` to match enum, the enumeration must be completely overwritten
- class: PHPStan\Rules\Comparison\MatchExpressionRule
arguments:
checkAlwaysTrueStrictComparison: %checkAlwaysTrueStrictComparison%
disableUnreachable: %featureToggles.disableUnreachableBranchesRules%
reportAlwaysTrueInLastCondition: %reportAlwaysTrueInLastCondition%
treatPhpDocTypesAsCertain: %treatPhpDocTypesAsCertain%
tags:
- phpstan.rules.rule