Skip to content
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

Adjust opt-in to be copy & pasteable into config file #8413

Closed
colszowka opened this issue Jul 29, 2020 · 2 comments
Closed

Adjust opt-in to be copy & pasteable into config file #8413

colszowka opened this issue Jul 29, 2020 · 2 comments

Comments

@colszowka
Copy link
Contributor

Is your feature request related to a problem? Please describe.

The recently adjusted opt-in behaviour to new cops comes with a warning printed on rubocop runs that lists all not-yet configured cops, like this:

The following cops were added to RuboCop, but are not configured. Please set Enabled to either `true` or `false` in your `.rubocop.yml` file:
 - Lint/DuplicateElsifCondition (0.88)
 - Lint/MixedRegexpCaptureTypes (0.85)
 - Style/AccessorGrouping (0.87)

Describe the solution you'd like

As I usually find myself wanting to opt-in to all new cops I would appreciate if the output would be formatted in a way that is directly copy&pasteable. I tried this out locally by adjusting the corresponding code in config loader to print like this instead:

The following cops were added to RuboCop, but are not configured. Please set Enabled to either `true` or `false` in your `.rubocop.yml` file:
Lint/DuplicateElsifCondition: # (new in 0.88)
  Enabled: true
Lint/MixedRegexpCaptureTypes: # (new in 0.85)
  Enabled: true
Style/AccessorGrouping: # (new in 0.87)
  Enabled: true

I would be willing to send a PR with the corresponding changes, but wanted to check in whether this is a change that would be accepted.

Thanks for the extremely useful tool!

@marcandre
Copy link
Contributor

I would be willing to send a PR

Yes please! 👍 😄

colszowka added a commit to colszowka/rubocop that referenced this issue Jul 29, 2020
@colszowka
Copy link
Contributor Author

colszowka commented Jul 29, 2020

@marcandre Here we go: #8414

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants