mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-02 19:16:39 +00:00
99 lines
4.2 KiB
Plaintext
99 lines
4.2 KiB
Plaintext
includes:
|
|
- ../vendor/symplify/phpstan-rules/config/code-complexity-rules.neon
|
|
- ../vendor/symplify/phpstan-rules/config/collector-rules.neon
|
|
- ../vendor/symplify/phpstan-rules/config/naming-rules.neon
|
|
- ../vendor/symplify/phpstan-rules/config/regex-rules.neon
|
|
- ../vendor/symplify/phpstan-rules/config/static-rules.neon
|
|
- ../vendor/symplify/phpstan-rules/config/configurable-rules.neon
|
|
|
|
services:
|
|
-
|
|
class: Symplify\PHPStanRules\Rules\ForbiddenNodeRule
|
|
tags: [phpstan.rules.rule]
|
|
arguments:
|
|
forbiddenNodes:
|
|
- PhpParser\Node\Expr\Empty_
|
|
- PhpParser\Node\Expr\ErrorSuppress
|
|
|
|
|
|
parameters:
|
|
universalObjectCratesClasses:
|
|
- Illuminate\Database\Eloquent\Model
|
|
reportUnmatchedIgnoredErrors: false
|
|
checkGenericClassInNonGenericObjectType: false # remove this rule when all other issues are solved.
|
|
ignoreErrors:
|
|
- '#Use value object over return of values#' # from simplify, ignore it.
|
|
- '#Use explicit names over dynamic ones#' # from simplify, ignore it.
|
|
- '#Use unique name to make classes easy to recognize#'
|
|
- '#Do not name "e", shorter than 2 chars#'
|
|
- '#Do not name "q", shorter than 2 chars#'
|
|
- '#with no value type specified in iterable type array#' # remove this rule when all other issues are solved.
|
|
- '#has no value type specified in iterable type array#' # remove this rule when all other issues are solved.
|
|
- '#is not allowed to extend#'
|
|
- '#switch is forbidden to use#'
|
|
- '#is neither abstract nor final#'
|
|
- '#has a nullable return type declaration#'
|
|
- '#with a nullable type declaration#'
|
|
- '#with null as default value#'
|
|
- '#is not covariant with PHPDoc type array#'
|
|
-
|
|
message: '#Constructor in [a-zA-Z0-9\\_]+ has parameter \$[a-zA-Z0-9\\_]+ with default value#'
|
|
paths:
|
|
- ../app/Exceptions/IntervalException.php
|
|
- ../app/Support/Navigation.php
|
|
-
|
|
message: '#but containers should not be injected#'
|
|
paths:
|
|
- ../app/Support/Authentication/RemoteUserGuard.php
|
|
-
|
|
message: '#Control structures using switch should not be used.#'
|
|
paths:
|
|
- ../app/Api/V1/Controllers/Data/DestroyController.php
|
|
- ../app/Console/Commands/Correction/FixAccountTypes.php
|
|
- ../app/Console/Commands/Upgrade/OtherCurrenciesCorrections.php
|
|
- ../app/Exceptions/GracefulNotFoundHandler.php
|
|
- ../app/Generator/Webhook/StandardMessageGenerator.php
|
|
- ../app/Support/Amount.php
|
|
- ../app/Support/Navigation.php
|
|
- ../app/Support/ParseDateString.php
|
|
- ../app/Support/Search/AccountSearch.php
|
|
- ../app/Support/Search/OperatorQuerySearch.php
|
|
- ../app/Support/Twig/General.php
|
|
- ../app/Transformers/RecurrenceTransformer.php
|
|
- ../app/Validation/AccountValidator.php
|
|
- ../app/Validation/RecurrenceValidation.php
|
|
- ../app/Validation/TransactionValidation.php
|
|
|
|
-
|
|
message: '#Function compact\(\) should not be used#'
|
|
paths:
|
|
- ../app/Generator/Report/Account/MonthReportGenerator.php
|
|
- ../app/Generator/Report/Audit/MonthReportGenerator.php
|
|
- ../app/Generator/Report/Budget/MonthReportGenerator.php
|
|
- ../app/Generator/Report/Category/MonthReportGenerator.php
|
|
- ../app/Generator/Report/Standard/MonthReportGenerator.php
|
|
- ../app/Generator/Report/Standard/MultiYearReportGenerator.php
|
|
- ../app/Generator/Report/Standard/YearReportGenerator.php
|
|
- ../app/Generator/Report/Tag/MonthReportGenerator.php
|
|
- ../app/Http/Controllers/Account/*.php
|
|
- ../app/Http/Controllers/Admin/*.php
|
|
- ../app/Http/Controllers/*.php
|
|
- ../app/Support/ExpandedForm.php
|
|
- ../app/Support/Form/AccountForm.php
|
|
- ../app/Support/Form/CurrencyForm.php
|
|
- ../app/Support/Form/FormSupport.php
|
|
-
|
|
message: '#Either catch a more specific exception#'
|
|
paths:
|
|
- ../app/Support/Form/FormSupport.php
|
|
paths:
|
|
- ../app
|
|
- ../database
|
|
- ../routes
|
|
- ../config
|
|
- ../bootstrap/app.php
|
|
|
|
# The level 8 is the highest level. original was 5
|
|
level: 1
|
|
|