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

Integrate Rubocop into the project #549

Open
jcouball opened this issue Jan 2, 2022 · 0 comments
Open

Integrate Rubocop into the project #549

jcouball opened this issue Jan 2, 2022 · 0 comments

Comments

@jcouball
Copy link
Member

jcouball commented Jan 2, 2022

Integrate Rubocop into this project

I propose that we integrate Rubocop into this project in order to promote more consistent code style and to increase our CodeClimate maintainability score (which is currently a "C").

Many times when I make code changes, my editor removes spaces at the end of lines, spaces from otherwise blank lines or converts tabs to spaces which clutters the diff output. I think that integrating Rubocop will help with this problem.

I propose the following Rubocop configuration which mostly takes the Rubocop defaults:

AllCops:
  # Output extra information for each offense to make it easier to diagnose:
  DisplayCopNames: true
  DisplayStyleGuide: true
  ExtraDetails: true
  # RuboCop enforces rules depending on the oldest version of Ruby which
  # your project supports:
  TargetRubyVersion: 2.3

# The default max line length is 80 characters
Layout/LineLength:
  Max: 120

# The DSL for the gemspec file make it very hard to limit block length:
Metrics/BlockLength:
  Exclude:
    - "*.gemspec"

# When writing minitest tests, it is very hard to limit test class length:
Metrics/ClassLength:
  Exclude:
    - "test/**/*_test.rb"
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

1 participant