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

Add latest rubocop and use Ruby 2.6+ #1311

Merged
merged 20 commits into from
Aug 17, 2021
Merged

Conversation

olleolleolle
Copy link
Member

@olleolleolle olleolleolle commented Aug 16, 2021

Description

This introduces the latest RuboCop version, and sets lower bound of Ruby support to 2.6.

This does the absolute minimum, to get it configured.

  • We landed some new rules, perhaps we'll go with "all new rules", soon, I don't know.
  • The TODO file grew a small amount.

See #1309

Todos

  • Add the new set of defaults
  • Re-run the auto-generated todo file

Additional Notes

We will see if there are many separate steps to take, if we need a big checklist & issues etc.

@olleolleolle olleolleolle changed the title Add latest rubocop and use 26 Add latest rubocop and use Ruby 2.6+ Aug 16, 2021
Copy link
Member

@iMacTia iMacTia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fantastic work @olleolleolle and well done keeping the todo file under control 👏
I just have a question about auto-correctable cops

.rubocop_todo.yml Outdated Show resolved Hide resolved
We are after the side-effect of setting something in the last match,
from this "useless" RegExp.
also Performance/RedundantSplitRegexpArgument.
# Configuration parameters: IgnoredMethods.
Metrics/PerceivedComplexity:
Max: 14

# Offense count: 3
Style/DocumentDynamicEvalDefinition:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I want to talk a bit about this rule, since the fix will have visual impact, and we'd like to pick the nicest alternative.

Copy link
Member

@iMacTia iMacTia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is good as is IMO, we can discuss the pending points offline and address in a follow-up

@olleolleolle olleolleolle merged commit abe78b5 into main Aug 17, 2021
@olleolleolle olleolleolle deleted the add-latest-rubocop-and-use-26 branch August 17, 2021 06:44
@olleolleolle olleolleolle linked an issue Aug 17, 2021 that may be closed by this pull request
@olleolleolle olleolleolle mentioned this pull request Aug 17, 2021
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

Successfully merging this pull request may close these issues.

Update Rubocop
2 participants