forked from mautic/mautic
-
Notifications
You must be signed in to change notification settings - Fork 3
/
rector.yaml
30 lines (27 loc) · 1.56 KB
/
rector.yaml
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
parameters:
sets:
- dead-code
paths:
- app/bundles
- plugins
exclude_paths:
- '*/tests/*'
- '*/Tests/*'
- '*/Test/*'
- '*/test/*'
- '*/InstallFixtures/*'
- '*/Fixtures/*'
- '*.html.php'
- '*.inc.php'
- '*.js.php'
- 'app/bundles/LeadBundle/Entity/LeadField.php' # Rector doesn't understand the lifecycle method.
- 'app/bundles/WebhookBundle/Entity/Webhook.php' # Rector doesn't understand the JMS serialization hacks.
- 'app/bundles/UserBundle/Entity/UserToken.php' # Rector doesn't understand the private prop $id is useful there.
- 'app/bundles/EmailBundle/Entity/EmailReplyRepository.php' # Method getTableAlias() is called only from the trait. Bad, bad. Excluding for now.
exclude_rectors:
- 'Rector\DeadCode\Rector\ClassMethod\RemoveUnusedParameterRector' # Causes BC breaks and broken services. Use only manually with caution.
- 'Rector\DeadCode\Rector\MethodCall\RemoveDefaultArgumentValueRector' # Doesn't play nicely every time.
- 'Rector\DeadCode\Rector\If_\SimplifyIfElseWithSameContentRector' # Removes code that is not the same.
- 'Rector\DeadCode\Rector\For_\RemoveDeadIfForeachForRector' # Problematic with some copy-pasted code.
- 'Rector\DeadCode\Rector\Ternary\TernaryToBooleanOrFalseToBooleanAndRector' # see https://github.com/rectorphp/rector/issues/2765
- 'Rector\DeadCode\Rector\Switch_\RemoveDuplicatedCaseInSwitchRector' # see https://github.com/rectorphp/rector/issues/2730