10056 Commits

Author SHA1 Message Date
Tomas Votruba
db15fb6f49
fix Symfony inline_function fallback (#4219) 2020-09-14 12:33:17 +00:00
Tomas Votruba
4711abebd1
[RemovingStatic] Add SingleStaticServiceToDynamicRector (#4212)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-13 12:36:29 +02:00
Tomas Votruba
c2dae7fcf4
load rector-recipe.php only in case of GenerateCommand (#4211) 2020-09-13 02:32:55 +02:00
dobryy
4e04d96b9c
[DX] PHPStan rule to check getNodeTypes() return classes of PhpParser\Node (#4210)
Co-authored-by: Tomas Votruba <tomas.vot@gmail.com>
2020-09-12 23:14:31 +00:00
dobryy
4fee8c6773
[DX] PHPStan rule to check, that value objects do not have value object suffix (#4206)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-13 01:08:21 +02:00
dobryy
28a55c973e
[DX] Add Rule that checks that Rule + value object have same starts (#4202)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-12 23:19:08 +02:00
Abdul Malik Ikhsan
88d5711436
Fixes #3789 add skip Option to exclude files by rule (#4182) 2020-09-12 11:52:08 +02:00
Leonardo Losoviz
abb9a3ef90
Downgrade PHP7.1 features: nullable types and void return type (#4192) 2020-09-12 11:50:13 +02:00
Tomas Votruba
61da1015b0
[RemovingStatic] Do not cause this in static method (#4204) 2020-09-12 00:13:48 +00:00
Tomas Votruba
89e042feb9
[RemovingStatic] Add support for union types (#4203) 2020-09-12 00:25:23 +02:00
Tomas Votruba
42f377c825
drop html from RectorRecipe, buggy and confusing, handle manually (#4199) 2020-09-11 14:08:19 +00:00
dobryy
a6444fb801
[DX] Configurable rule must have configure code sample, and vice versa (#4174)
* [DX] Configurable rule must have configure code sample, and vice versa

* Add ConfiguredCodeSample

* heredocs

* code sample

* fix class

* drop AbstractConfigurableMatchTypeRector

Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-11 11:21:48 +02:00
Tomas Votruba
59c5a5e5ba
[NodeRepository] Merge function like finder to NodeRepository (#4186)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-11 00:09:05 +02:00
Tomas Votruba
33b9ac6fb8
[ci] Add PHP Linter (#4188) 2020-09-10 22:05:34 +00:00
Tomas Votruba
f5f7ba76af
[NoreRepository] merge ClassLikeParsedNodesFinder to NodeRepository (#4185)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-10 14:56:54 +02:00
Tomas Votruba
7cab529bf8
Introduce NodeRepository, single place to get all nodes (#4183)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-10 12:24:43 +02:00
Tomas Votruba
44f383038f
[RemovingStatic] Add LocallyCalledStaticMethodToNonStaticRector (#4181)
* update docs

* [RemovingStatic] Add LocallyCalledStaticMethodToNonStaticRector

* [rector] [RemovingStatic] Add LocallyCalledStaticMethodToNonStaticRector

* [cs] [RemovingStatic] Add LocallyCalledStaticMethodToNonStaticRector

Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-10 07:27:03 +00:00
TomasVotruba
db9d18227e composer.json: add markdown file to check-cs 2020-09-09 23:58:12 +02:00
TomasVotruba
8b981eb912 colors 2020-09-09 23:57:46 +02:00
Abdul Malik Ikhsan
c17dae56dd
register check-markdown command to composer script (#4149)
* register check-markdown command to composer script

* remove .github/workflows/check_markdown.yml

* add --fix to vendor/bin/ecs check-markdown README.md

* update symplify/autowire-array-parameter to ^8.2.27 and symplify/easy-coding-standard to ^8.2.27
2020-09-09 18:05:38 +02:00
Tomas Votruba
4f1beae3fd
[DX] Fix NoAbstractMethodRule cases (#4180)
* decouple IsAbleFuncCallInterface

* decouple WithFunctionToNetteUtilsStringsRectorInterface

* decouple NodeTraversableInterface

* decouple RectorInterfaceAwareInterface

* [ci] disable markdown check to prevent user bothering
2020-09-09 09:07:14 +00:00
Leonardo Losoviz
5dbd454102
Remove DowngradeRectorInterface (#4179)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-09 11:03:05 +02:00
dobryy
f69ea0e023
[Naming] Rename foreach value variable to match method return type (#4130)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-09 10:52:43 +02:00
Leonardo Losoviz
7a498e328e
Split downgrade sets (#4175)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-09 10:32:28 +02:00
Bastian Konetzny
ee1894e5f8
Fixed invalid method name in code sample. (#4177) 2020-09-09 10:27:53 +02:00
Leonardo Losoviz
27fa9556d8
Added downgrade rules (#4172)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-08 17:18:49 +02:00
Leonardo Losoviz
b54a40aa61
[Downgrade PHP 8.0] mixed and static types (#4162)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-08 16:10:42 +02:00
Abdul Malik Ikhsan
bcb9580353
apply run ecs check-heredoc-nowdoc command to packages and rules directory (#4138) 2020-09-08 15:27:17 +02:00
Leonardo Losoviz
4197899608
Downgrade union type (#4150)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-08 15:25:38 +02:00
TomasVotruba
bed168b2e7 remove non-existing dir from sonar 2020-09-08 15:06:13 +02:00
Leonardo Losoviz
4eacc84b22
Organize downgrades by PHP version (#4147)
Co-authored-by: TomasVotruba <tomas.vot@gmail.com>
2020-09-08 13:12:38 +02:00
Tomas Votruba
6508aedd13
[Downgrade PHP 8.0] Add union types to doc types (#4082) 2020-09-08 12:00:38 +02:00
Abdul Malik Ikhsan
46e2b450b3
add check markdown github action workflow for fix README.md markdown file (#4134) 2020-09-08 11:41:32 +02:00
Leonardo Losoviz
ffd1e7fbec
Restructure class hierarchy to implement downgrade rules (#4142) 2020-09-08 11:40:56 +02:00
Tomas Votruba
a32b4fed64
add jean85-pretty-version (#4141) 2020-09-08 01:12:41 +00:00
Markus Staab
a03446e139
make EXCLUDE_PATHS work across different OSes (#4128) 2020-09-07 17:55:43 +02:00
Abdul Malik Ikhsan
6e2f798fe2
run ecs markdown-code-format to README.md (#4129) 2020-09-07 17:55:04 +02:00
Tomas Votruba
1a2e9cbb33
static fixes (#4140) 2020-09-07 17:40:46 +02:00
Leonardo Losoviz
a0f99c2c7f
Downgrade arrow functions (#4137)
* Extracted rule into abstract class for reuse

* Implemented rule

* Added rule to downgrade set

* Fixed rector-ci errors

* Fixed cs

* Preserve return type

* Direct assignment of parameters

* Use interface instead of abstract methods

* Moved abstract class under Php72

* Added test for params with type
2020-09-07 15:38:03 +02:00
Leonardo Losoviz
c6203e96d2
Downgrade null coalescing operator (#4135)
* Return `null` to signify no change to the node

* Implemented rector

* Added new rule to downgrade set

* Test requires PHP 7.4

* Wrapped code inside class
2020-09-07 14:50:42 +02:00
Hans-Helge Buerger
d6ff3a96cb
Fix example: exclude directory in config (#4136) 2020-09-07 11:19:24 +02:00
geryguilbon
a57d5b8882
Improved rule FollowRequireByDirRector (#4133) 2020-09-06 20:35:24 +02:00
Leonardo Losoviz
0deb805a31
Commented out vendor locking (#4132) 2020-09-05 12:34:38 +02:00
Leonardo Losoviz
71682d2b52
Abstract downgrade type + Implementation for object type (#4118) 2020-09-04 11:57:12 +02:00
jjthiessen
ff5b60826f
Correct various mysql_* to mysqli_* conversion bugs (#4119)
Co-authored-by: Jonathan Thiessen <jonathan.thiessen@terago.ca>
2020-09-03 20:49:31 +02:00
Tomas Votruba
a127bf16eb
revert [Experimental] Add safe_types option - #3535 (#4120) 2020-09-03 18:02:07 +00:00
TomasVotruba
3da57841db fix cakephp41 set 2020-09-03 19:52:58 +02:00
TomasVotruba
64912f3375 fix cs 2020-09-03 19:47:41 +02:00
TomasVotruba
a1f66b98da fix cakephp41 set 2020-09-03 19:17:31 +02:00
TomasVotruba
7214d83d9a fix inlined value object v0.8.6 2020-09-03 15:56:52 +02:00