Instant Upgrades with Rector
summary
Codebase migration uses an AST with nikic/php-parser and a set of automated rules so refactors apply patternwise not filewise, cutting 44,000 lines (200,000 total) across 151 routes in about 80 hours of rule development. Rector claims it fixes roughly 80% of upgrade chores, provides rule sets for Symfony, Nette, Twig, Doctrine, PHPUnit, can add typehints to remove PHPStan errors, and runs in CI to apply and verify changes automatically.
AI-written summary · about
chapters (7)
- 0:00Introduction
- 2:54Legacy code and frameworks
- 6:09Migrating frameworks with Rector
- 9:05Refactoring by pattern
- 10:53Rector's goals and benefits
- 12:04Daily code improvements
- 13:55Q&A
related talks
22mInstant Upgrades with Rector
40mRefactoring Huge Legacy PHP Applications - From 100 hours to minutes
29mTomas Votruba — Let Rector do the Boring Work
01h 06mRewriting Legacy Code
01h 02mRewriting 12-Year-Old Code
52mAutomate Drupal 9 upgrades: Addressing deprecated code as a community
50mPHP 8.2 - Just upgrade and go?
49mUpgrading Legacy to the Latest PHP Version
