-
-
Notifications
You must be signed in to change notification settings - Fork 687
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DX] "generate" command should generate files in specific set #4875
Comments
If you're using Rector as dependency, then it's correct. If you're contributing our repository, that would be a bug. But that's weird, because it worked for last 450 rules correctly. In the latter case, please provide GitHub Actions job, that shows this problem. |
I work as a contributor on our repository and I run:
Doing that the second command only asks one question and generates rules in |
I see. That's because the "package" has to be changed to "Symfony5" first. I'll move the category up, so it's harder to miss. |
What do you think about moving away from What I mean is that you run
Something similar to running |
Sounde doable. How would it include code samples that are used for RuleDefinition and test fixture? To avoid mixing 2 behavior, there should be option to invoke Q&A behavior: generate -i
generate --interactive In that case we can accept it. Are you willing to contribute it? |
Sure. Could you point me to the place where the current I would generate then some dummy CodeSamples that would have to be changed by hand, unfortunately. I don't see any other solution. |
We respect simple command naming convention, so "generate + comand" will find the class:
👍 If it's documented here https://github.com/rectorphp/rector/blob/master/docs/rector_recipe.md, it should be ok |
Hi, I'm thinking about way how to make Rector simpler and less ambiguous. We've got a feedback about its complexity and try to drop everything that is not neccessary, so 95 % of users can learn it faster and with less know-how. I've just realized we have this feature that I never used and I wanted to ask about your experience with it. How is usage of this feature? |
rectorphp/rector-src@c03fd2a [Performance] Avoid spl_object_hash() when has origNode attribute on AbstractRector::leaveNode() (#4875)
Feature Request
When you run
generate
command it only asks a question aboutcomposer.json
and generates all files in the default set:What I would like as a person working on a new Rectors is to get more questions about, for example, "bundle" for which the Rector should be created as well the name. As well we could check if the "bundle" (here: symfony5) exists and if not add it to
composer.json
by default without asking question.Expected result
The text was updated successfully, but these errors were encountered: