rectorphp/rector (rector/rector)
### [`v0.19.8`](https://togithub.com/rectorphp/rector/releases/tag/0.19.8): Released Rector 0.19.8
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.7...0.19.8)
#### New Features :partying_face:
- \[experimental] Add withTypeCoverageLevel() method to streamline Rector integration to new projects ([#5553](https://togithub.com/rectorphp/rector-src/pull/5553))
#### Bugfixes :bug:
- Cache null result on ProjectComposerJsonPhpVersionResolver ([#5559](https://togithub.com/rectorphp/rector-src/pull/5559))
- Real fix paths The given paths do not match any files on RectorConfigBuilder ([#5561](https://togithub.com/rectorphp/rector-src/pull/5561))
### [`v0.19.7`](https://togithub.com/rectorphp/rector/releases/tag/0.19.7): Released Rector 0.19.7
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.6...0.19.7)
#### Bugfixes :bug:
- \[TypeDeclaration] Skip assign in construct with method call property same name on RestoreDefaultNullToNullableTypePropertyRector ([#5556](https://togithub.com/rectorphp/rector-src/pull/5556))
- \[Privatization] Fix reprint with attribute on FinalizeTestCaseClassRector ([#5557](https://togithub.com/rectorphp/rector-src/pull/5557))
- \[DX] Fix missing Rector\RectorGenerator\Exception\ConfigurationException ([#5558](https://togithub.com/rectorphp/rector-src/pull/5558))
- Fix platform version resolution, use require first ([#5555](https://togithub.com/rectorphp/rector-src/pull/5555))
- bump template version (https://github.com/rectorphp/rector-src/commit/02a088c735b9b829c8f0dec445e71dea70e559bc)
### [`v0.19.6`](https://togithub.com/rectorphp/rector/releases/tag/0.19.6): Released Rector 0.19.6
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.5...0.19.6)
#### New Features and Changes :partying_face:
- \[EarlyReturn] Improve RemoveAlwaysElseRector to handle multiple ElseIfs ([#8178](https://togithub.com/rectorphp/rector/issues/8178)) ([#5521](https://togithub.com/rectorphp/rector-src/pull/5521)), Thanks [@pkvach](https://togithub.com/pkvach)!
- \[Privatization] Add FinalizeTestCaseClassRector ([#5539](https://togithub.com/rectorphp/rector-src/pull/5539))
- Add support for YieldFrom into places where Yield\_ is checked ([#5499](https://togithub.com/rectorphp/rector-src/pull/5499)), Thanks [@integer](https://togithub.com/integer)!
- \[Transform] Add RectorConfigBuilderRector ([#5551](https://togithub.com/rectorphp/rector-src/pull/5551))
- \[DX] Warn about run on /vendor directory ([#5525](https://togithub.com/rectorphp/rector-src/pull/5525))
- \[DX] PHP sets should not disable all other version-based rules ([#5527](https://togithub.com/rectorphp/rector-src/pull/5527))
- **\[stabilize] Deprecate FinalizeClassesWithoutChildrenRector as causing bugs without full context ([#5535](https://togithub.com/rectorphp/rector-src/pull/5535))**
#### Bugfixes :bug:
- **Fix xdebug handling ([#5544](https://togithub.com/rectorphp/rector-src/pull/5544)), Thanks [@staabm](https://togithub.com/staabm)!**
- Added 4 methods into RectorConfigBuilder ([#5524](https://togithub.com/rectorphp/rector-src/pull/5524)), Thanks [@Perf](https://togithub.com/Perf)!
- Fix AddMethodCallBasedStrictParamTypeRector if already has a type ([#5530](https://togithub.com/rectorphp/rector-src/pull/5530))
- \[CodingStyle] Return null on no change on StrictArraySearchRector ([#5528](https://togithub.com/rectorphp/rector-src/pull/5528))
- \[Php81] Allow nullable union on NullToStrictStringFuncCallArgRector ([#5532](https://togithub.com/rectorphp/rector-src/pull/5532))
- \[stabilize] Deprecate FinalizePublicClassConstantRector as not reliable and causes uncontroller changed ([#5534](https://togithub.com/rectorphp/rector-src/pull/5534))
- \[TypeDeclaration] Change bool to false or true docblock when union has false/true standalone type on ReturnUnionTypeRector ([#5543](https://togithub.com/rectorphp/rector-src/pull/5543))
- \[EarlyReturn] Skip append variable in PreparedValueToEarlyReturnRector ([#8390](https://togithub.com/rectorphp/rector/issues/8390)) ([#5545](https://togithub.com/rectorphp/rector-src/pull/5545)), Thanks [@pkvach](https://togithub.com/pkvach)!
- Fix make ReadOnlyPropertyRector skip if traits are used, as not reliable ([#5548](https://togithub.com/rectorphp/rector-src/pull/5548))
- Kick off basic rector.php with simpler and more practical rule ([#5552](https://togithub.com/rectorphp/rector-src/pull/5552))
#### Removed :skull:
- Exclude finalize rule from private set, to keep safer ([#5523](https://togithub.com/rectorphp/rector-src/pull/5523))
- \[Performance] Remove CollectedData on ProcessResult ([#5520](https://togithub.com/rectorphp/rector-src/pull/5520))
- \[stabilize] Remove family tree check from ClassMethodParamVendorLockResolver as not reliable ([#5536](https://togithub.com/rectorphp/rector-src/pull/5536))
- \[stabilize] Remove child classes from MixedTypeRector as not reliable ([#5537](https://togithub.com/rectorphp/rector-src/pull/5537))
- \[stabilize] Remove last children method checks ([#5538](https://togithub.com/rectorphp/rector-src/pull/5538))
### [`v0.19.5`](https://togithub.com/rectorphp/rector/releases/tag/0.19.5): Released Rector 0.19.5
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.4...0.19.5)
#### New Features :tada:
- \[Autoloading] Allow to define bootstrapFiles(\[**DIR** . '/some.phar']) on BootstrapFilesIncluder ([#5518](https://togithub.com/rectorphp/rector-src/pull/5518))
- add withPhpSets() methods ([#5519](https://togithub.com/rectorphp/rector-src/pull/5519))
### [`v0.19.4`](https://togithub.com/rectorphp/rector/releases/tag/0.19.4): Released Rector 0.19.4
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.3...0.19.4)
#### Bugfixes :bug:
- Fix configured rule ([#5517](https://togithub.com/rectorphp/rector-src/pull/5517))
### [`v0.19.3`](https://togithub.com/rectorphp/rector/releases/tag/0.19.3): Released Rector 0.19.3
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.2...0.19.3)
#### New Features ahd Changes :partying_face:
- **\[Config] Add RectorConfigBuilder ([#5503](https://togithub.com/rectorphp/rector-src/pull/5503))**
- Add gitlab to "setup-ci" command ([#5497](https://togithub.com/rectorphp/rector-src/pull/5497))
- **Add "custom-rule" command to make creating rules easy ([#5498](https://togithub.com/rectorphp/rector-src/pull/5498))**
- \[Windows] Rework add windows support on tests CI ([#5504](https://togithub.com/rectorphp/rector-src/pull/5504))
- make literal separator optional, as rather coding style and not always desired ([#5505](https://togithub.com/rectorphp/rector-src/pull/5505))
#### Bugfixes :bug:
- \[Php70] Skip inside Encapsed on ThisCallOnStaticMethodToStaticCallRector ([#5481](https://togithub.com/rectorphp/rector-src/pull/5481))
- \[Performance] Cache PHP version features on reading composer.json on PhpVersionProvider ([#5484](https://togithub.com/rectorphp/rector-src/pull/5484))
- Fix phpstan ([#5489](https://togithub.com/rectorphp/rector-src/pull/5489))
- \[Config] Restore default values for RectorConfig->parallel() config similar to original <=0.18.x version ([#5472](https://togithub.com/rectorphp/rector-src/pull/5472))
- \[Performance]\[PhpParser] Deprecate InlineCodeParser::parse(), extract into parseFile() and parseString() ([#5482](https://togithub.com/rectorphp/rector-src/pull/5482))
- \[CodeQuality] Skip surplus open square bracket on SimplifyRegexPatternRector ([#5494](https://togithub.com/rectorphp/rector-src/pull/5494))
- \[AutoImport] Skip start with \= short open tag on auto import ([#5496](https://togithub.com/rectorphp/rector-src/pull/5496))
- \[Testing] Deprecate FileInfoParser, use existing TestingParser instead ([#5501](https://togithub.com/rectorphp/rector-src/pull/5501))
- custom copy path fix ([#5502](https://togithub.com/rectorphp/rector-src/pull/5502))
- \[DX] Allow Arg in value resolver, as often used and intuitive ([#5512](https://togithub.com/rectorphp/rector-src/pull/5512))
- \[Windows] Support replace \r\n on DocBlockInliner ([#5513](https://togithub.com/rectorphp/rector-src/pull/5513))
- \[Php83] add string type to concat constant ([#5516](https://togithub.com/rectorphp/rector-src/pull/5516)), Thanks [@jdohuutin](https://togithub.com/jdohuutin)!
#### Removed :skull:
- \[Renaming] Remove namespace renames in ClassRename, as it should only rename references, not move to new namespace ([#5487](https://togithub.com/rectorphp/rector-src/pull/5487))
- \[Renaming] Remove rename class name ([#5488](https://togithub.com/rectorphp/rector-src/pull/5488))
### [`v0.19.2`](https://togithub.com/rectorphp/rector/releases/tag/0.19.2): Released Rector 0.19.2
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.1...0.19.2)
#### New features and Changes :tada:
- \[DX] Depreate heavy and conflicting Symfony/Twig/PHPUnit level sets ([#5477](https://togithub.com/rectorphp/rector-src/pull/5477))
- Remove collectors, as performance very costly and not practically useful ([#5470](https://togithub.com/rectorphp/rector-src/pull/5470))
#### Bugfixes :bug:
- **Fix repeated timeouts on CI - [https://github.com/rectorphp/rector/issues/8403](https://togithub.com/rectorphp/rector/issues/8403), [https://github.com/rectorphp/rector/issues/8396](https://togithub.com/rectorphp/rector/issues/8396)**
- Bump PHPStan to 1.10.56 ([#5471](https://togithub.com/rectorphp/rector-src/pull/5471))
- Remove collector interface and fix SpatieEnumClassToEnumRector already has underscore to double underscore ([#5473](https://togithub.com/rectorphp/rector-src/pull/5473))
- \[DX] Depreate heavy and conflicting Symfony/Twig/PHPUnit level sets ([#5477](https://togithub.com/rectorphp/rector-src/pull/5477))
#### Removed :skull:
- \[Performance] Remove unused AttributeKey::ARGUMENT_POSITION ([#5469](https://togithub.com/rectorphp/rector-src/pull/5469))
- \[Autoload] Remove src/core_namespace_aliases.php ([#5476](https://togithub.com/rectorphp/rector-src/pull/5476))
### [`v0.19.1`](https://togithub.com/rectorphp/rector/compare/0.19.0...0.19.1)
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.0...0.19.1)
### [`v0.19.0`](https://togithub.com/rectorphp/rector/releases/tag/0.19.0): Released Rector 0.19.0
[Compare Source](https://togithub.com/rectorphp/rector/compare/0.18.13...0.19.0)
In this release we merged 2 directories into `/src` to speed up class loading and make work with code easier. This leads to BC change in namespace for your custom rules:
```diff
-use Rector\Core\
+use Rector\
```
That's it!
#### New Features :partying_face:
- \[psr-4] Move /packages directory to /src under single Rector\ namespace ([#5414](https://togithub.com/rectorphp/rector-src/pull/5414))
- \[Arguments] Allow no default value on ArgumentAdderRector ([#5382](https://togithub.com/rectorphp/rector-src/pull/5382))
- **Add related polyfill interface to other PHP 8.0/7.3 rules** ([#5389](https://togithub.com/rectorphp/rector-src/pull/5389))
- \[CodingStyle] Add RemoveUselessAliasInUseStatementRector ([#5394](https://togithub.com/rectorphp/rector-src/pull/5394))
- \[Php83] Add CombineHostPortLdapUriRector ([#5397](https://togithub.com/rectorphp/rector-src/pull/5397))
- \[TypeDeclaration] optionally only add types for hard coded return values in `ReturnTypeFromStrictScalarReturnExprRector` ([#5364](https://togithub.com/rectorphp/rector-src/pull/5364)), Thanks [@RobertMe](https://togithub.com/RobertMe)!
- Add phpstan native cond types for getName() for nodes that always return a string ([#5413](https://togithub.com/rectorphp/rector-src/pull/5413))
- \[Strict] Add StaticProperty supporton may be unitialized static property on DisallowedEmptyRuleFixerRector ([#5428](https://togithub.com/rectorphp/rector-src/pull/5428))
- \[Php83] Add implements interface support on AddOverrideAttributeToOverriddenMethodsRector ([#5429](https://togithub.com/rectorphp/rector-src/pull/5429))
- \[cs] Make use of new ECS config ([#5445](https://togithub.com/rectorphp/rector-src/pull/5445))
#### Bugfixes :bug:
- \[TypeDeclaration] Add false and true in union support on ReturnUnionTypeRector ([#5355](https://togithub.com/rectorphp/rector-src/pull/5355))
- Skip classes without final and exception as possibly invoke child implement in AddVoidReturnTypeWhereNoReturnRector ([#5381](https://togithub.com/rectorphp/rector-src/pull/5381))
- Skip non-final class method with no content in AddVoidReturnTypeWhereNoReturnRector ([#5386](https://togithub.com/rectorphp/rector-src/pull/5386))
- \[TypeDeclaration] Allow add void return type on magic `__invoke()` method on AddVoidReturnTypeWhereNoReturnRector ([#5376](https://togithub.com/rectorphp/rector-src/pull/5376))
- Add `ReturnTypeFromStrictBoolReturnExprRector` support for if/else returns ([#5384](https://togithub.com/rectorphp/rector-src/pull/5384))
- Skip void without final keyword in ReturnNeverTypeRector as could be implemented with more precise children ([#5379](https://togithub.com/rectorphp/rector-src/pull/5379))
- Fix StrictArrayParamDimFetchRector for string access ([#5383](https://togithub.com/rectorphp/rector-src/pull/5383))
- Fix variable to property fetch update in ClassPropertyAssignToConstructorPromotionRector ([#5385](https://togithub.com/rectorphp/rector-src/pull/5385))
- \[Php] Fix filter cache on PolyfillPackagesProvider ([#5390](https://togithub.com/rectorphp/rector-src/pull/5390))
- \[Parallel] Fix missing --xdebug in WorkerCommand line on WorkerCommandLineFactory when --xdebug provided ([#5398](https://togithub.com/rectorphp/rector-src/pull/5398))
- Bump phpstan to 1.10.50 ([#5399](https://togithub.com/rectorphp/rector-src/pull/5399))
- \[Php83] Handle dynamic host and port values on CombineHostPortLdapUriRector ([#5401](https://togithub.com/rectorphp/rector-src/pull/5401))
- \[config] Extract RectorConfigValidator and handle config validation there ([#5404](https://togithub.com/rectorphp/rector-src/pull/5404))
- \[psr-4] Update Rector core test reference ([#5410](https://togithub.com/rectorphp/rector-src/pull/5410))
- \[cleanup] Decouple changelog generator ([#5412](https://togithub.com/rectorphp/rector-src/pull/5412))
- \[Strict] Handle may be unitialized property on DisallowedEmptyRuleFixerRector ([#5409](https://togithub.com/rectorphp/rector-src/pull/5409))
- Bump min. version to PHP 8.2 - readonly classes ([#5415](https://togithub.com/rectorphp/rector-src/pull/5415))
- Decouple LongAndDependentComplexRectorRule to cognitive-complexity package ([#5427](https://togithub.com/rectorphp/rector-src/pull/5427))
- \[TypeDeclaration] Skip with empty() check on StrictArrayParamDimFetchRector ([#5432](https://togithub.com/rectorphp/rector-src/pull/5432))
- \[TypeDeclaration] Allow both integer and string index array on StrictArrayParamDimFetchRector ([#5433](https://togithub.com/rectorphp/rector-src/pull/5433))
- \[TypeDeclaration] Skip re-assign with call and use as arg on StrictArrayParamDimFetchRector ([#5434](https://togithub.com/rectorphp/rector-src/pull/5434))
- \[CodeQuality] Handle crash with call inside loop on SimplifyForeachToCoalescingRector ([#5436](https://togithub.com/rectorphp/rector-src/pull/5436))
- \[TypeDeclaration] Handle with default null on ParamTypeByMethodCallTypeRector ([#5437](https://togithub.com/rectorphp/rector-src/pull/5437))
- \[NodeTypeResolver] Handle crash PHPStan\File\CouldNotReadFileException: Could not read file on IntermediateSourceLocator ([#5438](https://togithub.com/rectorphp/rector-src/pull/5438))
- Allows to convert Spatie enum names to snake upper case ([#5435](https://togithub.com/rectorphp/rector-src/pull/5435)), Thanks [@JoolsMcFly](https://togithub.com/JoolsMcFly)!
- fix: RenameMethodRector should handle NullsafeMethodCall ([#5444](https://togithub.com/rectorphp/rector-src/pull/5444)), Thanks [@nikophil](https://togithub.com/nikophil)!
- \[Php80]\[CodeQuality] Handle crash on ChangeSwitchToMatchRector + TernaryFalseExpressionToIfRector on under if else ([#5446](https://togithub.com/rectorphp/rector-src/pull/5446))
- Skip cond with side effect in RemoveDeadConditionAboveReturnRector ([#5424](https://togithub.com/rectorphp/rector-src/pull/5424))
- \[DeadCode] Skip nullable array on RemoveUnusedNonEmptyArrayBeforeForeachRector ([#5375](https://togithub.com/rectorphp/rector-src/pull/5375))
- Keep called method in RemoveEmptyClassMethodRector ([#5425](https://togithub.com/rectorphp/rector-src/pull/5425))
#### Removed :skull:
- \[DeadCode] Remove RemoveJustPropertyFetchForAssignRector as tailored for single case of private project, not practical for generic use ([#5418](https://togithub.com/rectorphp/rector-src/pull/5418))
- remove array spread from coding style, as often part of personal preference (https://github.com/rectorphp/rector-src/commit/a326b8504d37093f639245da0b283f588f954890)
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
â™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
[ ] If you want to rebase/retry this PR, check this box
This PR contains the following updates:
^0.18.0
->^0.19.0
Release Notes
rectorphp/rector (rector/rector)
### [`v0.19.8`](https://togithub.com/rectorphp/rector/releases/tag/0.19.8): Released Rector 0.19.8 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.7...0.19.8) #### New Features :partying_face: - \[experimental] Add withTypeCoverageLevel() method to streamline Rector integration to new projects ([#5553](https://togithub.com/rectorphp/rector-src/pull/5553))#### Bugfixes :bug: - Cache null result on ProjectComposerJsonPhpVersionResolver ([#5559](https://togithub.com/rectorphp/rector-src/pull/5559)) - Real fix paths The given paths do not match any files on RectorConfigBuilder ([#5561](https://togithub.com/rectorphp/rector-src/pull/5561)) ### [`v0.19.7`](https://togithub.com/rectorphp/rector/releases/tag/0.19.7): Released Rector 0.19.7 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.6...0.19.7) #### Bugfixes :bug: - \[TypeDeclaration] Skip assign in construct with method call property same name on RestoreDefaultNullToNullableTypePropertyRector ([#5556](https://togithub.com/rectorphp/rector-src/pull/5556)) - \[Privatization] Fix reprint with attribute on FinalizeTestCaseClassRector ([#5557](https://togithub.com/rectorphp/rector-src/pull/5557)) - \[DX] Fix missing Rector\RectorGenerator\Exception\ConfigurationException ([#5558](https://togithub.com/rectorphp/rector-src/pull/5558)) - Fix platform version resolution, use require first ([#5555](https://togithub.com/rectorphp/rector-src/pull/5555)) - bump template version (https://github.com/rectorphp/rector-src/commit/02a088c735b9b829c8f0dec445e71dea70e559bc) ### [`v0.19.6`](https://togithub.com/rectorphp/rector/releases/tag/0.19.6): Released Rector 0.19.6 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.5...0.19.6) #### New Features and Changes :partying_face: - \[EarlyReturn] Improve RemoveAlwaysElseRector to handle multiple ElseIfs ([#8178](https://togithub.com/rectorphp/rector/issues/8178)) ([#5521](https://togithub.com/rectorphp/rector-src/pull/5521)), Thanks [@pkvach](https://togithub.com/pkvach)! - \[Privatization] Add FinalizeTestCaseClassRector ([#5539](https://togithub.com/rectorphp/rector-src/pull/5539)) - Add support for YieldFrom into places where Yield\_ is checked ([#5499](https://togithub.com/rectorphp/rector-src/pull/5499)), Thanks [@integer](https://togithub.com/integer)! - \[Transform] Add RectorConfigBuilderRector ([#5551](https://togithub.com/rectorphp/rector-src/pull/5551)) - \[DX] Warn about run on /vendor directory ([#5525](https://togithub.com/rectorphp/rector-src/pull/5525)) - \[DX] PHP sets should not disable all other version-based rules ([#5527](https://togithub.com/rectorphp/rector-src/pull/5527)) - **\[stabilize] Deprecate FinalizeClassesWithoutChildrenRector as causing bugs without full context ([#5535](https://togithub.com/rectorphp/rector-src/pull/5535))**
#### Bugfixes :bug: - **Fix xdebug handling ([#5544](https://togithub.com/rectorphp/rector-src/pull/5544)), Thanks [@staabm](https://togithub.com/staabm)!** - Added 4 methods into RectorConfigBuilder ([#5524](https://togithub.com/rectorphp/rector-src/pull/5524)), Thanks [@Perf](https://togithub.com/Perf)! - Fix AddMethodCallBasedStrictParamTypeRector if already has a type ([#5530](https://togithub.com/rectorphp/rector-src/pull/5530)) - \[CodingStyle] Return null on no change on StrictArraySearchRector ([#5528](https://togithub.com/rectorphp/rector-src/pull/5528)) - \[Php81] Allow nullable union on NullToStrictStringFuncCallArgRector ([#5532](https://togithub.com/rectorphp/rector-src/pull/5532)) - \[stabilize] Deprecate FinalizePublicClassConstantRector as not reliable and causes uncontroller changed ([#5534](https://togithub.com/rectorphp/rector-src/pull/5534)) - \[TypeDeclaration] Change bool to false or true docblock when union has false/true standalone type on ReturnUnionTypeRector ([#5543](https://togithub.com/rectorphp/rector-src/pull/5543)) - \[EarlyReturn] Skip append variable in PreparedValueToEarlyReturnRector ([#8390](https://togithub.com/rectorphp/rector/issues/8390)) ([#5545](https://togithub.com/rectorphp/rector-src/pull/5545)), Thanks [@pkvach](https://togithub.com/pkvach)! - Fix make ReadOnlyPropertyRector skip if traits are used, as not reliable ([#5548](https://togithub.com/rectorphp/rector-src/pull/5548)) - Kick off basic rector.php with simpler and more practical rule ([#5552](https://togithub.com/rectorphp/rector-src/pull/5552))
#### Removed :skull: - Exclude finalize rule from private set, to keep safer ([#5523](https://togithub.com/rectorphp/rector-src/pull/5523)) - \[Performance] Remove CollectedData on ProcessResult ([#5520](https://togithub.com/rectorphp/rector-src/pull/5520)) - \[stabilize] Remove family tree check from ClassMethodParamVendorLockResolver as not reliable ([#5536](https://togithub.com/rectorphp/rector-src/pull/5536)) - \[stabilize] Remove child classes from MixedTypeRector as not reliable ([#5537](https://togithub.com/rectorphp/rector-src/pull/5537)) - \[stabilize] Remove last children method checks ([#5538](https://togithub.com/rectorphp/rector-src/pull/5538)) ### [`v0.19.5`](https://togithub.com/rectorphp/rector/releases/tag/0.19.5): Released Rector 0.19.5 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.4...0.19.5) #### New Features :tada: - \[Autoloading] Allow to define bootstrapFiles(\[**DIR** . '/some.phar']) on BootstrapFilesIncluder ([#5518](https://togithub.com/rectorphp/rector-src/pull/5518)) - add withPhpSets() methods ([#5519](https://togithub.com/rectorphp/rector-src/pull/5519)) ### [`v0.19.4`](https://togithub.com/rectorphp/rector/releases/tag/0.19.4): Released Rector 0.19.4 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.3...0.19.4) #### Bugfixes :bug: - Fix configured rule ([#5517](https://togithub.com/rectorphp/rector-src/pull/5517)) ### [`v0.19.3`](https://togithub.com/rectorphp/rector/releases/tag/0.19.3): Released Rector 0.19.3 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.2...0.19.3) #### New Features ahd Changes :partying_face: - **\[Config] Add RectorConfigBuilder ([#5503](https://togithub.com/rectorphp/rector-src/pull/5503))** - Add gitlab to "setup-ci" command ([#5497](https://togithub.com/rectorphp/rector-src/pull/5497)) - **Add "custom-rule" command to make creating rules easy ([#5498](https://togithub.com/rectorphp/rector-src/pull/5498))** - \[Windows] Rework add windows support on tests CI ([#5504](https://togithub.com/rectorphp/rector-src/pull/5504)) - make literal separator optional, as rather coding style and not always desired ([#5505](https://togithub.com/rectorphp/rector-src/pull/5505))
#### Bugfixes :bug: - \[Php70] Skip inside Encapsed on ThisCallOnStaticMethodToStaticCallRector ([#5481](https://togithub.com/rectorphp/rector-src/pull/5481)) - \[Performance] Cache PHP version features on reading composer.json on PhpVersionProvider ([#5484](https://togithub.com/rectorphp/rector-src/pull/5484)) - Fix phpstan ([#5489](https://togithub.com/rectorphp/rector-src/pull/5489)) - \[Config] Restore default values for RectorConfig->parallel() config similar to original <=0.18.x version ([#5472](https://togithub.com/rectorphp/rector-src/pull/5472)) - \[Performance]\[PhpParser] Deprecate InlineCodeParser::parse(), extract into parseFile() and parseString() ([#5482](https://togithub.com/rectorphp/rector-src/pull/5482)) - \[CodeQuality] Skip surplus open square bracket on SimplifyRegexPatternRector ([#5494](https://togithub.com/rectorphp/rector-src/pull/5494)) - \[AutoImport] Skip start with \= short open tag on auto import ([#5496](https://togithub.com/rectorphp/rector-src/pull/5496)) - \[Testing] Deprecate FileInfoParser, use existing TestingParser instead ([#5501](https://togithub.com/rectorphp/rector-src/pull/5501)) - custom copy path fix ([#5502](https://togithub.com/rectorphp/rector-src/pull/5502)) - \[DX] Allow Arg in value resolver, as often used and intuitive ([#5512](https://togithub.com/rectorphp/rector-src/pull/5512)) - \[Windows] Support replace \r\n on DocBlockInliner ([#5513](https://togithub.com/rectorphp/rector-src/pull/5513)) - \[Php83] add string type to concat constant ([#5516](https://togithub.com/rectorphp/rector-src/pull/5516)), Thanks [@jdohuutin](https://togithub.com/jdohuutin)!
#### Removed :skull: - \[Renaming] Remove namespace renames in ClassRename, as it should only rename references, not move to new namespace ([#5487](https://togithub.com/rectorphp/rector-src/pull/5487)) - \[Renaming] Remove rename class name ([#5488](https://togithub.com/rectorphp/rector-src/pull/5488)) ### [`v0.19.2`](https://togithub.com/rectorphp/rector/releases/tag/0.19.2): Released Rector 0.19.2 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.1...0.19.2) #### New features and Changes :tada: - \[DX] Depreate heavy and conflicting Symfony/Twig/PHPUnit level sets ([#5477](https://togithub.com/rectorphp/rector-src/pull/5477)) - Remove collectors, as performance very costly and not practically useful ([#5470](https://togithub.com/rectorphp/rector-src/pull/5470))
#### Bugfixes :bug: - **Fix repeated timeouts on CI - [https://github.com/rectorphp/rector/issues/8403](https://togithub.com/rectorphp/rector/issues/8403), [https://github.com/rectorphp/rector/issues/8396](https://togithub.com/rectorphp/rector/issues/8396)** - Bump PHPStan to 1.10.56 ([#5471](https://togithub.com/rectorphp/rector-src/pull/5471)) - Remove collector interface and fix SpatieEnumClassToEnumRector already has underscore to double underscore ([#5473](https://togithub.com/rectorphp/rector-src/pull/5473)) - \[DX] Depreate heavy and conflicting Symfony/Twig/PHPUnit level sets ([#5477](https://togithub.com/rectorphp/rector-src/pull/5477))
#### Removed :skull: - \[Performance] Remove unused AttributeKey::ARGUMENT_POSITION ([#5469](https://togithub.com/rectorphp/rector-src/pull/5469)) - \[Autoload] Remove src/core_namespace_aliases.php ([#5476](https://togithub.com/rectorphp/rector-src/pull/5476)) ### [`v0.19.1`](https://togithub.com/rectorphp/rector/compare/0.19.0...0.19.1) [Compare Source](https://togithub.com/rectorphp/rector/compare/0.19.0...0.19.1) ### [`v0.19.0`](https://togithub.com/rectorphp/rector/releases/tag/0.19.0): Released Rector 0.19.0 [Compare Source](https://togithub.com/rectorphp/rector/compare/0.18.13...0.19.0) In this release we merged 2 directories into `/src` to speed up class loading and make work with code easier. This leads to BC change in namespace for your custom rules: ```diff -use Rector\Core\ +use Rector\ ``` That's it! #### New Features :partying_face: - \[psr-4] Move /packages directory to /src under single Rector\ namespace ([#5414](https://togithub.com/rectorphp/rector-src/pull/5414)) - \[Arguments] Allow no default value on ArgumentAdderRector ([#5382](https://togithub.com/rectorphp/rector-src/pull/5382)) - **Add related polyfill interface to other PHP 8.0/7.3 rules** ([#5389](https://togithub.com/rectorphp/rector-src/pull/5389)) - \[CodingStyle] Add RemoveUselessAliasInUseStatementRector ([#5394](https://togithub.com/rectorphp/rector-src/pull/5394)) - \[Php83] Add CombineHostPortLdapUriRector ([#5397](https://togithub.com/rectorphp/rector-src/pull/5397)) - \[TypeDeclaration] optionally only add types for hard coded return values in `ReturnTypeFromStrictScalarReturnExprRector` ([#5364](https://togithub.com/rectorphp/rector-src/pull/5364)), Thanks [@RobertMe](https://togithub.com/RobertMe)! - Add phpstan native cond types for getName() for nodes that always return a string ([#5413](https://togithub.com/rectorphp/rector-src/pull/5413)) - \[Strict] Add StaticProperty supporton may be unitialized static property on DisallowedEmptyRuleFixerRector ([#5428](https://togithub.com/rectorphp/rector-src/pull/5428)) - \[Php83] Add implements interface support on AddOverrideAttributeToOverriddenMethodsRector ([#5429](https://togithub.com/rectorphp/rector-src/pull/5429)) - \[cs] Make use of new ECS config ([#5445](https://togithub.com/rectorphp/rector-src/pull/5445))
#### Bugfixes :bug: - \[TypeDeclaration] Add false and true in union support on ReturnUnionTypeRector ([#5355](https://togithub.com/rectorphp/rector-src/pull/5355)) - Skip classes without final and exception as possibly invoke child implement in AddVoidReturnTypeWhereNoReturnRector ([#5381](https://togithub.com/rectorphp/rector-src/pull/5381)) - Skip non-final class method with no content in AddVoidReturnTypeWhereNoReturnRector ([#5386](https://togithub.com/rectorphp/rector-src/pull/5386)) - \[TypeDeclaration] Allow add void return type on magic `__invoke()` method on AddVoidReturnTypeWhereNoReturnRector ([#5376](https://togithub.com/rectorphp/rector-src/pull/5376)) - Add `ReturnTypeFromStrictBoolReturnExprRector` support for if/else returns ([#5384](https://togithub.com/rectorphp/rector-src/pull/5384)) - Skip void without final keyword in ReturnNeverTypeRector as could be implemented with more precise children ([#5379](https://togithub.com/rectorphp/rector-src/pull/5379)) - Fix StrictArrayParamDimFetchRector for string access ([#5383](https://togithub.com/rectorphp/rector-src/pull/5383)) - Fix variable to property fetch update in ClassPropertyAssignToConstructorPromotionRector ([#5385](https://togithub.com/rectorphp/rector-src/pull/5385)) - \[Php] Fix filter cache on PolyfillPackagesProvider ([#5390](https://togithub.com/rectorphp/rector-src/pull/5390)) - \[Parallel] Fix missing --xdebug in WorkerCommand line on WorkerCommandLineFactory when --xdebug provided ([#5398](https://togithub.com/rectorphp/rector-src/pull/5398)) - Bump phpstan to 1.10.50 ([#5399](https://togithub.com/rectorphp/rector-src/pull/5399)) - \[Php83] Handle dynamic host and port values on CombineHostPortLdapUriRector ([#5401](https://togithub.com/rectorphp/rector-src/pull/5401)) - \[config] Extract RectorConfigValidator and handle config validation there ([#5404](https://togithub.com/rectorphp/rector-src/pull/5404)) - \[psr-4] Update Rector core test reference ([#5410](https://togithub.com/rectorphp/rector-src/pull/5410)) - \[cleanup] Decouple changelog generator ([#5412](https://togithub.com/rectorphp/rector-src/pull/5412)) - \[Strict] Handle may be unitialized property on DisallowedEmptyRuleFixerRector ([#5409](https://togithub.com/rectorphp/rector-src/pull/5409)) - Bump min. version to PHP 8.2 - readonly classes ([#5415](https://togithub.com/rectorphp/rector-src/pull/5415)) - Decouple LongAndDependentComplexRectorRule to cognitive-complexity package ([#5427](https://togithub.com/rectorphp/rector-src/pull/5427)) - \[TypeDeclaration] Skip with empty() check on StrictArrayParamDimFetchRector ([#5432](https://togithub.com/rectorphp/rector-src/pull/5432)) - \[TypeDeclaration] Allow both integer and string index array on StrictArrayParamDimFetchRector ([#5433](https://togithub.com/rectorphp/rector-src/pull/5433)) - \[TypeDeclaration] Skip re-assign with call and use as arg on StrictArrayParamDimFetchRector ([#5434](https://togithub.com/rectorphp/rector-src/pull/5434)) - \[CodeQuality] Handle crash with call inside loop on SimplifyForeachToCoalescingRector ([#5436](https://togithub.com/rectorphp/rector-src/pull/5436)) - \[TypeDeclaration] Handle with default null on ParamTypeByMethodCallTypeRector ([#5437](https://togithub.com/rectorphp/rector-src/pull/5437)) - \[NodeTypeResolver] Handle crash PHPStan\File\CouldNotReadFileException: Could not read file on IntermediateSourceLocator ([#5438](https://togithub.com/rectorphp/rector-src/pull/5438)) - Allows to convert Spatie enum names to snake upper case ([#5435](https://togithub.com/rectorphp/rector-src/pull/5435)), Thanks [@JoolsMcFly](https://togithub.com/JoolsMcFly)! - fix: RenameMethodRector should handle NullsafeMethodCall ([#5444](https://togithub.com/rectorphp/rector-src/pull/5444)), Thanks [@nikophil](https://togithub.com/nikophil)! - \[Php80]\[CodeQuality] Handle crash on ChangeSwitchToMatchRector + TernaryFalseExpressionToIfRector on under if else ([#5446](https://togithub.com/rectorphp/rector-src/pull/5446)) - Skip cond with side effect in RemoveDeadConditionAboveReturnRector ([#5424](https://togithub.com/rectorphp/rector-src/pull/5424)) - \[DeadCode] Skip nullable array on RemoveUnusedNonEmptyArrayBeforeForeachRector ([#5375](https://togithub.com/rectorphp/rector-src/pull/5375)) - Keep called method in RemoveEmptyClassMethodRector ([#5425](https://togithub.com/rectorphp/rector-src/pull/5425))
#### Removed :skull: - \[DeadCode] Remove RemoveJustPropertyFetchForAssignRector as tailored for single case of private project, not practical for generic use ([#5418](https://togithub.com/rectorphp/rector-src/pull/5418)) - remove array spread from coding style, as often part of personal preference (https://github.com/rectorphp/rector-src/commit/a326b8504d37093f639245da0b283f588f954890)
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
â™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Renovate Bot.