[experimental] Add --kaizen option to apply only first X rules at a time#6876
[experimental] Add --kaizen option to apply only first X rules at a time#6876TomasVotruba merged 4 commits intomainfrom
Conversation
342a3b4 to
e7a625d
Compare
3f68321 to
0d1d4f7
Compare
|
Please correct me if I understood badly the implementation but if I understand correctly the usage of the kaizen option will be to run then then and so on. If the first 10 rules don't make any change, I would have run 10 times for nothing, until do some change that I can review. That could do the job, but what I had in mind had some extra-automation. Like just running and rector does:
Then I can commit the changes or ignore the rule and run again the
This way I'm saving rector runs. |
|
It's a bit different. It should apply at least first X rules, where X is So if we run: vendor/bin/rector --kaizen 2It will apply first 2 rules that change anything. If there are no changes, it means all sets and rules are applied and |
|
Ok, so basically my usage would be to run and commiting changes (or ignoring the rule) between every run until a run cannot change anything and it means |
|
Exactly 👍 If you feel like you want to progress faster, e.g. when codebase is stable, |
|
Let's ship this to test in the wild 👍 |
|
@TomasVotruba @samsonasik @VincentLanglet I am testing it, and it seems not work |
|
@shakaran it seems using -vendor/bin/rector --kaizen 5
+vendor/bin/rector --kaizen=5 |
|
@shakaran I created new PR to handle it: |
|
This pull request has been automatically locked because it has been closed for 150 days. Please open a new PR if you want to continue the work. |




Not ready for review yet, WIP